Class

# MobileHTMLViewer

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

## Description

A scrollable HTML viewer control.

## Properties

<div class="rst-class">

table-centered_columns_3_and_4

</div>

| Name                                                      | Type                                                          | Read-Only | Shared |
|-----------------------------------------------------------|---------------------------------------------------------------|-----------|--------|
| `AccessibilityHint<mobilehtmlviewer.accessibilityhint>`   | `String</api/data_types/string>`                              |           |        |
| `AccessibilityLabel<mobilehtmlviewer.accessibilitylabel>` | `String</api/data_types/string>`                              |           |        |
| `CanGoBack<mobilehtmlviewer.cangoback>`                   | `Boolean</api/data_types/boolean>`                            | ✓         |        |
| `CanGoForward<mobilehtmlviewer.cangoforward>`             | `Boolean</api/data_types/boolean>`                            | ✓         |        |
| `ControlCount<mobilehtmlviewer.controlcount>`             | `Integer</api/data_types/integer>`                            | ✓         |        |
| `Enabled<mobilehtmlviewer.enabled>`                       | `Boolean</api/data_types/boolean>`                            |           |        |
| `Height<mobilehtmlviewer.height>`                         | `Integer</api/data_types/integer>`                            | ✓         |        |
| `Left<mobilehtmlviewer.left>`                             | `Integer</api/data_types/integer>`                            | ✓         |        |
| `LockBottom<mobilehtmlviewer.lockbottom>`                 | `Boolean</api/data_types/boolean>`                            |           |        |
| `LockLeft<mobilehtmlviewer.lockleft>`                     | `Boolean</api/data_types/boolean>`                            |           |        |
| `LockRight<mobilehtmlviewer.lockright>`                   | `Boolean</api/data_types/boolean>`                            |           |        |
| `LockTop<mobilehtmlviewer.locktop>`                       | `Boolean</api/data_types/boolean>`                            |           |        |
| `Name<mobilehtmlviewer.name>`                             | `String</api/data_types/string>`                              | ✓         |        |
| `Parent<mobilehtmlviewer.parent>`                         | `MobileUIControl</api/user_interface/mobile/mobileuicontrol>` | ✓         |        |
| `TintColor<mobilehtmlviewer.tintcolor>`                   | `ColorGroup</api/graphics/colorgroup>`                        |           |        |
| `Top<mobilehtmlviewer.top>`                               | `Integer</api/data_types/integer>`                            | ✓         |        |
| `Visible<mobilehtmlviewer.visible>`                       | `Boolean</api/data_types/boolean>`                            |           |        |
| `Width<mobilehtmlviewer.width>`                           | `Integer</api/data_types/integer>`                            | ✓         |        |

## Methods

<div class="rst-class">

table-centered_column_4

</div>

| Name                                                            | Parameters                                                                                                                                                | Returns                                                       | Shared |
|-----------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------|--------|
| `AddConstraint<mobilehtmlviewer.addconstraint>`                 | constraint As `iOSLayoutConstraint</api/ios/ioslayoutconstraint>`, name As `String</api/data_types/string>` = ""                                          |                                                               |        |
| `AddControl<mobilehtmlviewer.addcontrol>`                       | child As `MobileUIControl</api/user_interface/mobile/mobileuicontrol>`, isBeingAdded As `Boolean</api/data_types/boolean>` = `False</api/language/false>` |                                                               |        |
| `Cancel<mobilehtmlviewer.cancel>`                               |                                                                                                                                                           |                                                               |        |
| `ClearFocus<mobilehtmlviewer.clearfocus>`                       |                                                                                                                                                           |                                                               |        |
| `Constraint<mobilehtmlviewer.constraint>`                       | name As `String</api/data_types/string>`                                                                                                                  | `iOSLayoutConstraint</api/ios/ioslayoutconstraint>`           |        |
| `ControlAt<mobilehtmlviewer.controlat>`                         | index As `Integer</api/data_types/integer>`                                                                                                               | `MobileUIControl</api/user_interface/mobile/mobileuicontrol>` |        |
| `Controls<mobilehtmlviewer.controls>`                           |                                                                                                                                                           | `Iterable</api/language/iterable>`                            |        |
| `ExecuteJavaScript<mobilehtmlviewer.executejavascript>`         | js As `String</api/data_types/string>`                                                                                                                    |                                                               |        |
| `ExecuteJavaScriptSync<mobilehtmlviewer.executejavascriptsync>` | js As `String</api/data_types/string>`                                                                                                                    | `Variant</api/data_types/variant>`                            |        |
| `GoBack<mobilehtmlviewer.goback>`                               |                                                                                                                                                           |                                                               |        |
| `GoForward<mobilehtmlviewer.goforward>`                         |                                                                                                                                                           |                                                               |        |
| `Handle<mobilehtmlviewer.handle>`                               |                                                                                                                                                           | `Ptr</api/data_types/additional_types/ptr>`                   |        |
| `LoadPage<mobilehtmlviewer.loadpage>`                           | file As `FolderItem</api/files/folderitem>`                                                                                                               |                                                               |        |
|                                                                 | html As `String</api/data_types/string>`                                                                                                                  |                                                               |        |
| `LoadURL<mobilehtmlviewer.loadurl>`                             | url As `String</api/data_types/string>`                                                                                                                   |                                                               |        |
| `Refresh<mobilehtmlviewer.refresh>`                             |                                                                                                                                                           |                                                               |        |
| `RemoveConstraint<mobilehtmlviewer.removeconstraint>`           | constraint As `iOSLayoutConstraint</api/ios/ioslayoutconstraint>`                                                                                         |                                                               |        |
|                                                                 | name As `String</api/data_types/string>`                                                                                                                  |                                                               |        |
| `RemoveControl<mobilehtmlviewer.removecontrol>`                 | child As `MobileUIControl</api/user_interface/mobile/mobileuicontrol>`                                                                                    |                                                               |        |
| `SetFocus<mobilehtmlviewer.setfocus>`                           |                                                                                                                                                           |                                                               |        |

## Events

<div class="rst-class">

table-centered_column_4

</div>

| Name                                                                | Parameters                                                                                          | Returns                                         |
|---------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------|-------------------------------------------------|
| `CancelLoad<mobilehtmlviewer.cancelload>`                           | url As `String</api/data_types/string>`                                                             | `Boolean</api/data_types/boolean>`              |
| `Closing<mobilehtmlviewer.closing>`                                 |                                                                                                     |                                                 |
| `DocumentBegin<mobilehtmlviewer.documentbegin>`                     | url As `String</api/data_types/string>`                                                             |                                                 |
| `DocumentComplete<mobilehtmlviewer.documentcomplete>`               | url As `String</api/data_types/string>`                                                             |                                                 |
| `DocumentProgressChanged<mobilehtmlviewer.documentprogresschanged>` | url As `String</api/data_types/string>`, percentageComplete As `Integer</api/data_types/integer>`   |                                                 |
| `Error<mobilehtmlviewer.error>`                                     | errorNumber As `Integer</api/data_types/integer>`, errorMessage As `String</api/data_types/string>` |                                                 |
| `JavaScriptRequest<mobilehtmlviewer.javascriptrequest>`             | method As `String</api/data_types/string>`, parameters() As `Variant</api/data_types/variant>`      | `String</api/data_types/string>`                |
| `JavaScriptResult<mobilehtmlviewer.javascriptrequest>`              | result As `String</api/data_types/string>`                                                          |                                                 |
| `NewWindow<mobilehtmlviewer.newwindow>`                             | url As `String</api/data_types/string>`                                                             | <span class="title-ref">MobileHTMLViewer</span> |
| `Opening<mobilehtmlviewer.opening>`                                 |                                                                                                     |                                                 |
| `TitleChanged<mobilehtmlviewer.titlechanged>`                       | newTitle As `String</api/data_types/string>`                                                        |                                                 |

## Property descriptions

<div id="mobilehtmlviewer.accessibilityhint">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.AccessibilityHint

**AccessibilityHint** As `String</api/data_types/string>`

> The accessibility hint is a longer description that is read aloud when VoiceOver is enabled.
>
> ``` xojo
> Me.AccessibilityHint = "Click to calculate the value and display the next screen."
> ```
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This property is not currently supported for Android.
>
> </div>

<div id="mobilehtmlviewer.accessibilitylabel">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.AccessibilityLabel

**AccessibilityLabel** As `String</api/data_types/string>`

> The accessibility label of of a control is a short name that is read aloud when VoiceOver is enabled.
>
> ``` xojo
> Me.AccessibilityLabel = "Calculate the value."
> ```

<div id="mobilehtmlviewer.cangoback">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.CanGoBack

**CanGoBack** As `Boolean</api/data_types/boolean>`

> If `True</api/language/true>`, it indicates that there is a prior page that can be navigated to using `GoBack<mobilehtmlviewer.goback>`.
>
> This property is read-only.
>
> This code in the `DocumentComplete<mobilehtmlviewer.documentcomplete>` event handler disables a Back button if there is no prior page:
>
> ``` xojo
> BackButton.Enabled = Me.CanGoBack
> ```

<div id="mobilehtmlviewer.cangoforward">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.CanGoForward

**CanGoForward** As `Boolean</api/data_types/boolean>`

> If `True</api/language/true>`, it indicates that there is a next page that can be navigated to using `GoForward<mobilehtmlviewer.goforward>`.
>
> This property is read-only.
>
> This code in the `DocumentComplete<mobilehtmlviewer.documentcomplete>` event handler disables a Forward button if there is no next page:
>
> ``` xojo
> ForwardButton.Enabled = Me.CanGoForward
> ```

<div id="mobilehtmlviewer.controlcount">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.ControlCount

**ControlCount** As `Integer</api/data_types/integer>`

> The number of child controls in the control.
>
> This property is read-only.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>

<div id="mobilehtmlviewer.enabled">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Enabled

**Enabled** As `Boolean</api/data_types/boolean>`

> Indicates whether the control is enabled or disabled.
>
> Disable the button:
>
> ``` xojo
> Button1.Enabled = False
> ```

<div id="mobilehtmlviewer.height">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Height

**Height** As `Integer</api/data_types/integer>`

> The height of the control.
>
> This property is read-only on iOS.

<div id="mobilehtmlviewer.left">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Left

**Left** As `Integer</api/data_types/integer>`

> The left position of the control.
>
> This property is read-only on iOS.

<div id="mobilehtmlviewer.lockbottom">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.LockBottom

**LockBottom** As `Boolean</api/data_types/boolean>`

> Determines whether the bottom edge of the control should stay at a set distance from the bottom edge of the parent control, if there is one, or the owning screen.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This property is not currently supported for iOS. Use constraints instead.
>
> </div>
>
> This property can be set in the control's Inspector. The following example sets it in code.
>
> ``` xojo
> Me.LockBottom = True
> ```

<div id="mobilehtmlviewer.lockleft">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.LockLeft

**LockLeft** As `Boolean</api/data_types/boolean>`

> Determines whether the left edge of the control should stay at a set distance from the left edge of the parent control, if there is one, or the owning screen.
>
> LockLeft and Locktop default to `True</api/language/true>` when you add a new control to a screen. Existing controls will be altered only if LockRight and/or LockBottom are not set. *LockLeft* has no effect unless *LockRight* is `True</api/language/true>`.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This property is not currently supported for iOS. Use constraints instead.
>
> </div>
>
> This property can be set in the control's Inspector. The following example sets it in code.
>
> ``` xojo
> Me.LockLeft = True
> ```

<div id="mobilehtmlviewer.lockright">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.LockRight

**LockRight** As `Boolean</api/data_types/boolean>`

> Determines whether the right edge of the control should stay at a set distance from the right edge of the parent control, if there is one, or the owning screen.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This property is not currently supported for iOS. Use constraints instead.
>
> </div>
>
> This property can be set in the control's Inspector. The following example sets it in code.
>
> ``` xojo
> Me.LockRight = True
> ```

<div id="mobilehtmlviewer.locktop">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.LockTop

**LockTop** As `Boolean</api/data_types/boolean>`

> Determines whether the top edge of the control should stay at a set distance from the top edge of the parent control, if there is one, or the owning screen.
>
> LockTop and LockLeft default to `True</api/language/true>` when you add a control to a screen. Existing controls will be altered only if LockRight and/or LockBottom are not set. *LockTop* has no effect unless *LockBottom* is `True</api/language/true>`.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This property is not currently supported for iOS. Use constraints instead.
>
> </div>
>
> This property can be set in the control's Inspector. The following example sets it in code.
>
> ``` xojo
> Me.LockTop = True
> ```

<div id="mobilehtmlviewer.name">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Name

**Name** As `String</api/data_types/string>`

> The name of the control.
>
> This property is read-only.

<div id="mobilehtmlviewer.parent">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Parent

**Parent** As `MobileUIControl</api/user_interface/mobile/mobileuicontrol>`

> The parent (sometimes called a "Super") class of the control.
>
> This property is read-only.

<div id="mobilehtmlviewer.tintcolor">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.TintColor

**TintColor** As `ColorGroup</api/graphics/colorgroup>`

> Changes a control's tint color.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>
>
> On iOS, the following controls support TintColor:
>
> | Enum        | Description                                                                  |
> |-------------|------------------------------------------------------------------------------|
> | PopupMenu   | The background color will be drawn in the TintColor.                         |
> | ProgressBar | The area indicating the value of the control will be drawn in the TintColor. |
> | Slider      | The area indicating the value of the control will be drawn in the TintColor. |
> | TextArea    | The cursor and text highlight color will be drawn in the TintColor.          |
> | TextField   | The cursor and text highlight color will be drawn in the TintColor.          |

<div id="mobilehtmlviewer.top">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Top

**Top** As `Integer</api/data_types/integer>`

> The top position of the control.
>
> This property is read-only on iOS.

<div id="mobilehtmlviewer.visible">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Visible

**Visible** As `Boolean</api/data_types/boolean>`

> Indicates whether the control is visible.
>
> Make a button invisible:
>
> ``` xojo
> Button1.Visible = False
> ```

<div id="mobilehtmlviewer.width">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Width

**Width** As `Integer</api/data_types/integer>`

> The width of the control.
>
> This property is read-only on iOS.

## Method descriptions

<div id="mobilehtmlviewer.addconstraint">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.AddConstraint

**AddConstraint**(constraint As `iOSLayoutConstraint</api/ios/ioslayoutconstraint>`, name As `String</api/data_types/string>` = "")

> Adds a *constraint* to the control. The optional *name* parameter can be used to `remove a constraint<mobileuicontrol.removeconstraint>` that was added via code.
>
> This *constraint* is used by child controls that have been added to this control.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>

<div id="mobilehtmlviewer.addcontrol">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.AddControl

**AddControl**(child As `MobileUIControl</api/user_interface/mobile/mobileuicontrol>`, isBeingAdded As `Boolean</api/data_types/boolean>` = `False</api/language/false>`)

> Adds a *child* control to the control. When the value of *isBeingAdded* is `True</api/language/true>`, the Opening event is triggered for the child control being added.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>

<div id="mobilehtmlviewer.cancel">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Cancel

**Cancel**

> Cancels any current operations.
>
> ``` xojo
> Me.Cancel
> ```

<div id="mobilehtmlviewer.clearfocus">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.ClearFocus

**ClearFocus**

> Removes the focus from the control.
>
> ``` xojo
> TextField1.ClearFocus
> ```

<div id="mobilehtmlviewer.constraint">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Constraint

**Constraint**(name As `String</api/data_types/string>`) As `iOSLayoutConstraint</api/ios/ioslayoutconstraint>`

> Gets a reference to a named constraint so that you can modify its settings in code.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>
>
> Change an existing (and named) constraint of a control on the Screen:
>
> ``` xojo
> ' "TAWidth" is a width constraint for a TextField that has been given
> ' a name in the auto-layout Inspector properties.
> Var c As iOSLayoutConstraint = Self.Constraint("TAWidth")
> c.Offset = 200
> ```

<div id="mobilehtmlviewer.controlat">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.ControlAt

**ControlAt**(index As `Integer</api/data_types/integer>`) As `MobileUIControl</api/user_interface/mobile/mobileuicontrol>`

> Gets the child control at the specified *index*.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>

<div id="mobilehtmlviewer.controls">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Controls

**Controls** As `Iterable</api/language/iterable>`

> Allows you to iterate through all the controls that have been added to this control.

<div class="important">

<div class="title">

Important

</div>

This is supported for iOS only.

</div>

<div id="mobilehtmlviewer.executejavascript">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.ExecuteJavaScript

**ExecuteJavaScript**(js As `String</api/data_types/string>`)

> Asynchronously executes the passed JavaScript in the context of the currently loaded page.
>
> On Android, this causes the `JavaScriptResult<mobilehtmlviewer.javascriptresult>` event to fire passing it values returned by the JavaScript.
>
> Attempting to execute JavaScript before the page finishes loading (or if no page is loaded) is undefined and is unlikely to work.
>
> This code will populate the search field on the wikipedia page (assuming it was previously loaded):
>
> ``` xojo
> Var jsSrc As String
> jsSrc = "document.forms[0].elements['search'].value=""xojo"";"
> HTMLViewer1.ExecuteJavaScript(jsSrc)
> ```
>
> This code writes text to the HTML document:
>
> ``` xojo
> Var this As String
> this = "document.writeln(""hello"");"
> HTMLViewer1.ExecuteJavaScript(this)
> ```

<div id="mobilehtmlviewer.executejavascriptsync">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.ExecuteJavaScriptSync

**ExecuteJavaScriptSync**(js As `String</api/data_types/string>`) As `Variant</api/data_types/variant>`

> Synchronously executes the passed JavaScript in the context of the currently loaded page and returns the result. Only strings and numbers may be returned.
>
> Attempting to execute JavaScript before the page finishes loading (or if no page is loaded) is undefined and is unlikely to work.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>

<div id="mobilehtmlviewer.goback">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.GoBack

**GoBack**

> Navigates to the prior page.
>
> On a back button Pressed event handler, you can write:
>
> ``` xojo
> HTMLViewer1.GoBack
> ```

<div id="mobilehtmlviewer.goforward">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.GoForward

**GoForward**

> Navigates to the next page.
>
> On a forward button Pressed event handler, you can write:
>
> ``` xojo
> HTMLViewer1.GoForward
> ```

<div id="mobilehtmlviewer.handle">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Handle

**Handle** As `Ptr</api/data_types/additional_types/ptr>`

> The handle to the underlying native OS control.

<div id="mobilehtmlviewer.loadpage">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.LoadPage

**LoadPage**(file As `FolderItem</api/files/folderitem>`)

> Displays the HTML passed.

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.LoadPage

**LoadPage**(html As `String</api/data_types/string>`)

> Displays the *html* passed.
>
> iOS sandboxing of the app and the HTML Viewer can prevent the HTML Viewer from seeing files that are in the app's Documents folder. This code can be used to provide access to files in the Documents folder:
>
> ``` xojo
> Declare Function NSClassFromString Lib "Foundation.framework" (clsName As CFStringRef) As ptr
> Declare Function URLWithString Lib "Foundation.framework" Selector "URLWithString:" (id As Ptr, URLString As CFStringRef) As Ptr
>
> Declare Sub loadFileURL Lib "UIKit.framework" Selector "loadFileURL:allowingReadAccessToURL:" (obj As Ptr, url As Ptr, readAccessURL As Ptr)
>
> ' htmlFile is a FolderItem from SpecialFolder.Documents
> Var nsURL As Ptr = URLWithString(NSClassFromString("NSURL"), htmlFile.URLPath)
> Var readURL As Ptr = URLWithString(NSClassFromString("NSURL"), htmlFile.parent.URLPath)
>
> loadFileURL(HTMLViewer1.Handle, nsURL, readURL) ' Display the contents in an MobileHTMLViewer
> ```

<div id="mobilehtmlviewer.loadurl">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.LoadURL

**LoadURL**(url As `String</api/data_types/string>`)

> Displays the specified *url*.
>
> Be sure to include the appropriate prefix, such as "<https://>".
>
> To load HTML from a file on the device or to load HTML as a `String</api/data_types/string>` directly, use `LoadPage<mobilehtmlviewer.loadpage>`.
>
> Display wikipedia:
>
> ``` xojo
> HTMLViewer1.LoadURL("https://www.wikipedia.org")
> ```

<div id="mobilehtmlviewer.refresh">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Refresh

**Refresh**

> Marks the control so that it will be redrawn during the next event loop.
>
> Call Refresh to force a Canvas to redraw itself:
>
> ``` xojo
> Canvas1.Refresh
> ```

<div id="mobilehtmlviewer.removeconstraint">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.RemoveConstraint

**RemoveConstraint**(constraint As `iOSLayoutConstraint</api/ios/ioslayoutconstraint>`)

> Removes a *constraint* from the control.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

**RemoveConstraint**(name As `String</api/data_types/string>`)

> Removes the constraint with the *name* passed from the `Screen</api/user_interface/mobile/mobilescreen>`.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>

<div id="mobilehtmlviewer.removecontrol">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.RemoveControl

**RemoveControl**(child As `MobileUIControl</api/user_interface/mobile/mobileuicontrol>`)

> Removes the control from the control.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This is supported for iOS only.
>
> </div>

<div id="mobilehtmlviewer.setfocus">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.SetFocus

**SetFocus**

> Sets the focus to the control.
>
> ``` xojo
> TextField1.SetFocus
> ```

## Event descriptions

<div id="mobilehtmlviewer.cancelload">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.CancelLoad

**CancelLoad**(url As `String</api/data_types/string>`) As `Boolean</api/data_types/boolean>`

> Returns a `Boolean</api/data_types/boolean>`. Return `True</api/language/true>` to cancel loading the page.

<div id="mobilehtmlviewer.closing">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Closing

**Closing**

> Called when the control's layout is closing.

<div id="mobilehtmlviewer.documentbegin">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.DocumentBegin

**DocumentBegin**(url As `String</api/data_types/string>`)

> Fires when the HTML page is starting to load.

<div id="mobilehtmlviewer.documentcomplete">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.DocumentComplete

**DocumentComplete**(url As `String</api/data_types/string>`)

> Called when the HTML page is finished loading.

<div id="mobilehtmlviewer.documentprogresschanged">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.DocumentProgressChanged

**DocumentProgressChanged**(url As `String</api/data_types/string>`, percentageComplete As `Integer</api/data_types/integer>`)

> Fires when the progress has been updated. If *percentageComplete* is -1, the percentage cannot be determined.

<div id="mobilehtmlviewer.error">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Error

**Error**(errorNumber As `Integer</api/data_types/integer>`, errorMessage As `String</api/data_types/string>`)

> Fires when an error occurs.
>
> The errors you receive are the [standard HTTP Status Codes](http://en.wikipedia.org/wiki/List_of_HTTP_status_codes).

<div id="mobilehtmlviewer.javascriptrequest">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.JavaScriptRequest

**JavaScriptRequest**(method As `String</api/data_types/string>`, parameters() As `Variant</api/data_types/variant>`) As `String</api/data_types/string>`

> Called when a JavaScript executed via `ExecuteJavaScript<mobilehtmlviewer.executejavascript>` or `ExecuteJavaScriptSync<mobilehtmlviewer.executejavascriptsync>` calls `executeInXojo()` or `executeInXojoSync()` on iOS or `xojo.execute()` on Android.
>
> <div class="note">
>
> <div class="title">
>
> Note
>
> </div>
>
> **iOS:** A JavaScript executed via `ExecuteJavaScript<mobilehtmlviewer.executejavascript>` or `ExecuteJavaScriptSync<mobilehtmlviewer.executejavascriptsync>` can call `executeInXojo()` or `executeInXojoSync()` on iOS to pass data back to the HTMLViewer via this event. Both can be passed any number of parameters though the first parameter must be a string. For all subsequent parameters, only strings and numbers are supported. The `executeInXojo()` method is asynchronous and thus will not receive a value returned by this event. The `executeInXojoSync()` method is synchronous and thus should be called as a function as it will receive the value returned by this event.
>
> </div>
>
> <div class="note">
>
> <div class="title">
>
> Note
>
> </div>
>
> **Android:** A JavaScript executed via `ExecuteJavaScript<mobilehtmlviewer.executejavascript>` can call `xojo.execute()` on Android to pass data back to the HTMLViewer via this event. A method name and up to 5 parameters can be passed back to Xojo.
>
> </div>

<div id="mobilehtmlviewer.javascriptresult">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.JavaScriptResult

**JavaScriptResult**(result As `String</api/data_types/string>`)

> Called on Android only when `ExecuteJavaScript<mobilehtmlviewer.executejavascript>` has been called and has been passed a JavaScript that calls `xojo.execute()`.
>
> The JavaScript can pass back to this event a method name and up to five parameters.
>
> <div class="important">
>
> <div class="title">
>
> Important
>
> </div>
>
> This event is supported for Android only.
>
> </div>

<div id="mobilehtmlviewer.newwindow">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.NewWindow

**NewWindow**(url As `String</api/data_types/string>`) As <span class="title-ref">MobileHTMLViewer</span>

> Called when the HTML on page requests that a *url* be opened in a new HTML viewer.
>
> Return an instance of an **HTMLViewer** to load the page in that viewer or `Return</api/language/return>` `Nil</api/language/nil>` if you do not want to allow URL to open at all.

<div id="mobilehtmlviewer.opening">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.Opening

**Opening**

> Called when the control's layout is opening.
>
> This is where you typically put initialization code.
>
> This example in the Opening event of a label sets its text to "Hello":
>
> ``` xojo
> Me.Text = "Hello"
> ```

<div id="mobilehtmlviewer.titlechanged">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

MobileHTMLViewer.TitleChanged

**TitleChanged**(newTitle As `String</api/data_types/string>`)

> Fires when the Title of the Web page has been determined or has changed.
>
> The renderer, which varies by OS, determines the maximum number of characters that are returned in *newTitle*. You should test this in your projects to determine a maximum number of characters, keeping in mind that this could change at any time due to the underlying renderer and operating system.

## Notes

iOS requires the use of secure "https" connections or the page will not display.

## Compatibility

|                       |        |
|-----------------------|--------|
| **Project Types**     | Mobile |
| **Operating Systems** | All    |

<div class="seealso">

`MobileUIControl</api/user_interface/mobile/mobileuicontrol>` parent class; `URLConnection</api/networking/urlconnection>` class

</div>
