Returns the specified applet object.
Set variable = object.Item ( Index ) |
- Index
- Required. A Variant that specifies the name or index of the applet.
Applet Object
Index is a variant specifying the applet to reference. It can be either the index or the name of the applet. For example, if your ArcPad application contains an applet named "MyApplet" that has an index of 2, the following two lines of code will yield the same result:
Set theApplet = Application.Applets.Item(2)
Set theApplet = Application.Applets.Item("MyApplet")
The Item method is the default method for the Applets collection. Therefore, the following two lines of code will yield the same result:
Set theApplet = Application.Applets.Item("MyApplet")
Set theApplet = Application.Applets("MyApplet")
Set theApplet = Application.Applets.Item(2)
Set theApplet = Application.Applets.Item("MyApplet")
The Item method is the default method for the Applets collection. Therefore, the following two lines of code will yield the same result:
Set theApplet = Application.Applets.Item("MyApplet")
Set theApplet = Application.Applets("MyApplet")
Displays the number of forms present in the first applet loaded in a message box.
Get Applet Forms Example (VBScript) | Copy Code |
---|---|
Sub GetApplet1Forms Dim objMyApplet, objTheForms Set objMyApplet = Application.Applets.Item (1) Set objTheForms = objMyApplet.Forms Application.MessageBox "The applet has " & objTheForms.Count & " forms", apInformation End Sub |
Get Applet Forms Example (JScript) | Copy Code |
---|---|
function GetApplet1Forms() { var objMyApplet = Application.Applets.Item(1); objTheForms = objMyApplet.Forms; Application.MessageBox("The applet has " + objTheForms.Count + " forms"); } |