WidgetID Property

This member of Class WaveLinkWidget is supported on: Palm, CE

The WidgetID Property retrieves the unique identifier for the current widget.

Syntax

public int getWidgetID()

Returns

The unique widget identifier

Remarks

The WidgetID Property is read-only. The unique widget ID is automatically assigned when you create the widget.

The widget ID is returned through a previous RFInput Method.

To process user input based on the general input type (command key, widget input, scanned input), use the LastInputType Method.

Example

WaveLinkIO ioIface = new WaveLinkIO();

WaveLinkFactory factoryIface = new WaveLinkFactory();

WaveLinkWidgetCollection colIface = new WaveLinkWidgetCollection();

WaveLinkWidget Quit;

string resultStr;

 

// Create "Quit" widget (not shown).

.

.

.

try {

//Use RFInput or GetEvent to obtain input

resultStr = ioIface.GetEvent();

switch(ioIface.LastInputType())

{

case ioIface.WLCOMMANDTYPE:

//Process command type

break;

case ioIface.WLKEYTYPE:

//Process keyed command

break;

case ioIface.WLWIDGETTYPE:

if(ioIface.LastExtendedType() == Quit.getWidgetID())

; //Quit button pressed, exit process

break;

}

}

catch (WaveLinkError wlErr) {

//Do error handling

}

 


Was this article useful?    

The topic was:

Inaccurate

Incomplete

Not what I expected

Other

Privacy and Legal