This is a bunch of tips and techniques related to Oracle PL/SQL and Forms.

Right-click on a component to display its properties and methods.
The Java code
HandleMouseEvent.java
The implementation class of the Bean Item
oracle.forms.fd.HandleMouseEvent
The methods you can call
Set_Custom_Property('BLOCK.ITEM', 1, 'SETEVENT', 'parameter');
Set_Custom_Property('BLOCK.ITEM', 1, 'ALLOWEVENT', 'true|false');
This event is raised by the bean to inform Forms that a mouse event has occured.
4 properties are provided:
- MSGEVENT : event raised (mouse enter, exit, click, move, press)
- MSGITEM : class name of the component
- MSGCOORD : coordinates of the mouse pointer
- MSGBTMOUSE : mouse button number
IF (eventName='SENDMSG') THEN
-- get the mouse message --
eventValues := get_parameter_list(:system.custom_item_event_parameters);
get_parameter_attr(eventValues,'MSGEVENT',eventValueType, LC$Event);
get_parameter_attr(eventValues,'MSGITEM',eventValueType, LC$Item);
get_parameter_attr(eventValues,'MSGCOORD',eventValueType, LC$Coord);
get_parameter_attr(eventValues,'MSGBTMOUSE',eventValueType, LC$Button);
LC$Msg := LC$Event
|| ' object=' || LC$Item
|| ' at ' || LC$Coord
|| ' mouse=' || LC$Button ;
clear_message;
Message(LC$Msg, no_acknowledge) ;
Synchronize ;
This event is raised by the bean to inform Forms that the property and method information of the component has been sent.
In the sample dialog, this information is stored in a Text item, then displayed via the Edit_TextItem() Forms built-in.
It can be displayed by right-clicking on anywhere on the screen.
ELSIF (eventName='SENDPROPS') THEN
-- get the component properties --
eventValues := get_parameter_list(:system.custom_item_event_parameters);
get_parameter_attr(eventValues,'MSGPROPS',eventValueType, LC$Msg);
:BL.PROPERTIES := Replace(LC$Msg, '/n', CHR(10));
Set_Custom_Property('BL.BEAN', 1, 'ALLOWEVENT', 'false' ) ;
Go_Item('BL.PROPERTIES');
edit_textitem ;
Set_Custom_Property('BL.BEAN', 1, 'ALLOWEVENT', 'true' ) ;
END IF;
The sample dialog
. Download the handlemouseevent.zip file
. Unzip the file
. copy the handlemouseevent.jar file in the <ORACLE_HOME>/forms/java directory
. Edit your /forms/server/formsweb.cfg file to add this jar file
. Open the MOUSEEVENT.fmb module (Oracle Forms 10.1.2)
. Compile all and run the module