bqoEvent (Object)

Member of:

Parameters

Description:

Passes event-related information as an optional parameter to the Event handler (OnClick handler). The bqoEvent has two properties: ClickX and ClickY. When the OnClient event occurs, the event handler has access to the event related information needed to process it. For example, the event might require the position of the mouse cursor for a picture, OnClick event, or information about which table column was clicked for a table embedded section object. If ClickX and ClickY values cannot be read, 0 is returned.

Note:

In the Object Model hierarchy, Parameters contains all parameters passed to the handler. Even though JavaScript allows an arbitrary numbers of parameters to be passed to a function, the Object Model event handler is not a trure JavaScript function.It is an external function that ishandled by the current Object Model framework.. Consequently, it is subject to the restrictions imposed by the Object Model framework.

Example:

This example shows to read the values on different sectors of a picture on an OnClick Event. Values are written to the Console:

TBConsole.Text = TBConsole.Text + "\r\nPic1 Start"
TBConsole.Text = TBConsole.Text + "\r\nXCoord: " + bqoEvent.ClickX
TBConsole.Text = TBConsole.Text + "\r\nYCoord: " + bqoEvent.ClickY

if (bqoEvent.ClickX > 390 && bqoEvent.ClickX < 480 && bqoEvent.ClickY >280 && bqoEvent.ClickY <425)
{
TBConsole.Text = TBConsole.Text + "\r\nFront Wheel"
}
else
{
TBConsole.Text = TBConsole.Text + "\r\nNot a Wheel"
}

TBConsole.Text = TBConsole.Text + "\r\nXCoord: " +  bqoEvent.ClickX
TBConsole.Text = TBConsole.Text + "\r\nYCoord: " + bqoEvent.ClickY

bqoEvent.ClickX = bqoEvent.ClickX - 50
bqoEvent.ClickY = bqoEvent.ClickY + 50

TBConsole.Text = TBConsole.Text + "\r\nXCoord: " +  bqoEvent.ClickX
TBConsole.Text = TBConsole.Text + "\r\nYCoord: " + bqoEvent.ClickY

Picture2.OnClick(bqoEvent)

TBConsole.Text = TBConsole.Text + "\r\nPic1 End"