Form: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
== Description == | |||
Forms act as containers for controls. To go to a new form, use the ChangeForm() function. | Forms act as containers for controls. To go to a new form, use the ChangeForm() function. | ||
Line 7: | Line 7: | ||
The information on a form can be submitted to a URL by calling the form.submit() function. The values for all controls on the form which have their Name property defined will be appended to the URL as an HTML query string. | The information on a form can be submitted to a URL by calling the form.submit() function. The values for all controls on the form which have their Name property defined will be appended to the URL as an HTML query string. | ||
== Properties == | |||
Standard [[properties and methods|properties]] are supported, plus: | Standard [[properties and methods|properties]] are supported, plus: | ||
Line 32: | Line 32: | ||
|} | |} | ||
== Events == | |||
{| class="wikitable" | {| class="wikitable" | ||
Line 45: | Line 45: | ||
|} | |} | ||
== Example == | |||
<pre> | <pre> | ||
Line 53: | Line 53: | ||
</pre> | </pre> | ||
== Output == | |||
<pre> | <pre> | ||
Line 59: | Line 59: | ||
</pre> | </pre> | ||
== Related Items == | |||
[[changeform|CHANGEFORM]], [[properties and methods|PROPERTIES]], [[events|EVENTS]], [[geturlparameter|GETURLPARAMETER]] | [[changeform|CHANGEFORM]], [[properties and methods|PROPERTIES]], [[events|EVENTS]], [[geturlparameter|GETURLPARAMETER]] | ||
[[Category:Language Reference]] |
Revision as of 01:13, 17 August 2012
Description
Forms act as containers for controls. To go to a new form, use the ChangeForm() function.
To add a Form to your app, choose Add Form from the Project menu at the top of the screen. Forms can be deleted in the Project Explorer.
The information on a form can be submitted to a URL by calling the form.submit() function. The values for all controls on the form which have their Name property defined will be appended to the URL as an HTML query string.
Properties
Standard properties are supported, plus:
backgroundimage | A background image to display. jQuery Mobile only. |
height | The height of the form. Default is 460 pixels. |
left | The left position of the form. Use this for forms that are not full screen. |
method | GET or POST. The method that the http form is sent by. |
openMode | Should the form be open at startup? Classic framework only. |
URL | The URL to be called when the form is submitted using the submit() function. |
width | The width of the form. Default is 320 pixels. |
reset() | Clear all fields on the form. Runtime only. |
submit() | Submit the data on the form to the specified URL. Runtime only. |
Events
onhide() | Called when form hidden as a result of ChangeForm() |
onkeypress(e) | Called when a key is tapped on a form. |
onshow() | Called by firstform and when form is shown as a result of ChangeForm. |
onsubmit() | Called when a form is submitted. |
Example
Function btnSendData_onclick() Form1.submit() End Function
Output
(URL is called with values in the query string)