onsubmit Property

Microsoft FrontPage Visual Basic

onsubmit Property

Returns or sets a Variant that represents the value of the onsubmit attribute that is the name of the script to run when the onsubmit event fires.

expression.onsubmit

expression    Required. An expression that returns one of the objects in the Applies To list.

Example

The following example sets the onsubmit attribute for the first FORM element in the active document.

    Dim objForm As FPHTMLFormElement
    
Set objForm = ActiveDocument.forms.Item(0)
    
objForm.onsubmit = "script()"