This event occurs when a when user clicks a button field on the form.
SyntaxButton_OnClick Form , ButtonName )
- The form object.
- The name of the button field that was clicked.
You can use this event to perform tasks such validating user input for a form field or populating other form field values on the form.
Function Button_OnClick(Form,ButtonName) 'Write custom code to lookup the user's home directory. Form.SetFieldValue “Path”, LookupHomeDirectory(Form.UserName) End Function