SetRequired (client-side)

Use this routine to set the required flag for the page and set a warning message to be displayed in the event that an attempt is made to save the page when one or more required fields are empty.

Definition

SetRequired(sWarnMsg)

Parameters

sWarnMsg

A string containing a warning message phrased as "You have made incomplete changes to properties. Click 'OK' to discard the changes and exit."

Return Value

None.

Remarks

There are two common ways in which this routine can be called:

  • As the handler of the OnRequire event of the master EditSheet for the page (set as an attribute of the container element of the EditSheet HTC):

    sWarnMsg = "You have made incomplete changes to properties. " & _
               "Click 'OK' to discard the changes and exit."
    . . .
    onrequire="SetRequired(sWarnMsg)"
    
  • From within the handler of the OnRequire event of the master EditSheet for the page.

This routine is only available after the taskbar has been inserted by calling either InsertTaskBar or InsertEditTaskBar.

This routine is available in the include file ActionPageUtil.asp.

See Also

Client-Side Routines

SetDirty (client-side)

SetValid (client-side)

Server-Side Routines


All rights reserved.