tWebNavigateData

See Also: String, Declaring Variables, Struct

 

Purpose

tWebNavigateData is a structured type that is used to represent information about a row in Web Application Framework lists and grids.

 

Type Declaration

Struct tWebNavigateData

    Integer eNavigateType

    Integer iTable

    Integer iColumn

    String sRowID

    Boolean bNewRecord

    Boolean bReadOnly

    Boolean bSaveBeforeNavigate

    tNameValuePair[] NamedValues

End_Struct

 

Struct Members

Integer eNavigateType

This contains the navigate-from type. When NavigateForward is sent, this type is determined for you and is then moved to this member. Valid values are nfFromMain, nfFromChild, nfFromParent and nfUndefined.

Integer iTable

This is the table number associated with the invoking object that started the navigate forward process. If the value is non-zero, it is expected that there will a DataDictionary Object (DDO) in the view for this table. If the invoking object is data bindable (i.e., if it supports the Entry_Item syntax), this table value will be used here.  If it is not data bindable, the Main_File value of the invoking view’s DDO Server is used. This is usually maintained by the framework.

Integer iColumn

This is the table column number associated with the invoking object that started the navigate forward process. If the invoking object is data bindable (i.e., if it supports the Entry_Item syntax), this bound column value will be used here.  If it is not data bindable, it will be 0. This is usually maintained by the framework.

String sRowID

During forward navigation, this is set to the a serialized version of the RowId associated with iTable. During back navigation, this will be set to the RowId of the view being closed. This is usually maintained by the framework.

Boolean bNewRecord

During forward navigation, the developer can set this to True to indicate that the view being navigated to will be cleared for new data entry. Normally, this would be set in OnGetNavigateForwardData when moving from a Select view to a Zoom view.

Boolean bReadOnly

During forward navigation, the developer can set this to True to indicate that the view being navigated should be read only. Normally, this would be set in OnGetNavigateForwardData when moving from a Select view to a Zoom view.

Boolean bSaveBeforeNavigate

This allows you to specify that the data in the invoking view must be saved before a forward navigation. When set True, a save will be attempted before the navigation. If this save fails or there was nothing to save (an empty record) the navigation is canceled. Normally, this would be set in OnGetNavigateForwardData when moving from a Zoom view to a child Select or Zoom view.

tNameValuePair[] NamedValues

This is an array of name/value pairs. This can be used by the developer to pass additional data back and forth between the invoking view and the invoked view. The values and meanings of these named data pairs must be defined by the developer. They have no meaning and are not used by the framework. These would be set in OnGetNavigateForwardData and OnGetNavigateBackData. If set, you will need to write code to get these data values and act on them. This is often done in the OnNavigateFoward and OnNavigateBack events. Methods exist in the cWebView class that allows you to add named value pairs to this array (NamedValueAdd) and to find a value based on its name (NamedValueGet and NamedValueIndex).

 

Syntax

Use tWebNavigateData.pkg

:

tWebNavigateData {variableName}

 

Declaring variables

This section is here for completeness and consistency. You'll probably never declare and instantiate tWebNavigateData variables, but instead just access and use the data of existing tWebNavigateData parameters passed by the Web Application Framework.

 

To declare tWebNavigateData variables, use the name of the type (tWebNavigateData) followed by the variable name.

tWebNavigateData MyWebNavigateData

See struct variables for more details of instantiating struct types.