onbeforeprint |
This event is fired before the print dialog is invoked. The print dialog gets invoked after you click the Print button in the toolbar of the XForm.
Syntax
| DesignTime | This is a design-time property and can be set through the property sheet of the control. |
Event Information
| To invoke | Click on the toolbar's Print button to print the XForm. |
| Default Action | Initiates any events associated with this event. |
| Named Script | onbeforeprint |
Event Object Properties
| Property | Description |
|---|---|
| returnValue | Boolean that denotes whether the Print operation should be continued or not. To cancel the event, user can set the value of this property to false. |
| true | Default. Print operation should be continued. |
| false | Print operation should not be continued. |
| srcElement | Reference to the Print button. |
An event handler can access the event object and its properties through the eventObject available as a parameter on the handler.
This sample code demonstrates the event:
function onbeforePrintHandler(eventObject)
{
eventObject.returnValue = false;
return false;
}