Jeudi 9 février 2006
4
09
/02
/2006
10:10
Purpose
This is a Javabean component that allows to intercept each key typed in a text field
Then, there is no need to use a Forms timer to intercept each key typed.
The java code
Get the Java code here
Forms configuration
- . Copy the keytyped.jar file in the /forms/java directory
- . Edit the /forms/server/formsweb.cfg file to add the jar file to the archive_jini variable
archive_jini=f90all_jinit.jar,……,keytyped.jar
Implementation Class property
oracle.forms.fd.KeyTyped
Properties that can be set
The text of the item
set_custom_property( 'BLOCK.BEAN_ITEM', 1, 'SETTEXT', 'the_text');
The position of the cursor
set_custom_property( 'BLOCK.BEAN_ITEM', 1, 'SETPOS', 'n');
The colors of the item
set_custom_property( 'BLOCK.BEAN_ITEM', 1, 'SETBG', 'rgb value');
set_custom_property( 'BLOCK.BEAN_ITEM', 1, 'SETFG', 'rgb value');
e.g.
set_custom_property( 'BLOCK.BEAN_ITEM', 1, 'SETBG', '200,10,0');
Properties that can be read
The text of the item
get_custom_property( 'BLOCK.BEAN_ITEM', 1, 'GETTEXT', '');
The last character typed
get_custom_property( 'BLOCK.BEAN_ITEM', 1, 'GETCHAR', '');
The keyboard state modifier
get_custom_property( 'BLOCK.BEAN_ITEM', 1, 'GETMODIFIER', '');
Events that can be raised by the bean
A character was typed
KEYTYPED
The sample dialog
- . Download the KeyTyped.zip file
- . Unzip the KeyTyped.zip file
- . Copy the keytyped.jar file in your /forms/java/ directory
- . Edit your /forms/server/formsweb.cfg file
- . Open the KEYTYPED.fmb module (Oracle Forms 9.0.2)
- . Compile all and run the module
Par Oracle Forms community
-
Publié dans : Bean - Text items
0
-
Recommander
Jeudi 16 février 2006
4
16
/02
/2006
16:23
Purpose
This is a JavaBean component that allows to edit a HTML styled text field.
You can use the Ctrl+B, Ctrl+I and Ctrl+U keys to toggle some simple attributes like Bold, Italic and Underline.
The java codeGet the source code here
Forms configuration. Copy the htmlpane.jar file in the /forms/java directory
. Edit the /forms/server/formsweb.cfg file to add the jar file to the archive_jini variable archive_jini=f90all_jinit.jar,……,htmlpane.jar
Implementation Class property
oracle.forms.fd.HtmlPaneThe properties you can set
Set the text
Set_Custom_Property( 'BL.BEAN_AREA', 1, 'SET_TEXT', 'html text' ) ;The properties you can get
Get the HTML textVarchar2 := Get_Custom_Property( 'BL.BEAN_AREA', 1, 'GET_TEXT' ) ;
The events you can raise from the Bean
BEAN_QUITTEDraised when the Bean lose the focus to prevent Forms that its content may have changed.
The sample dialog
. Download the htmlpane.zip file . Unzip the file
. Edit your /forms/server/formsweb.cfg file
. Open the HTML_PANE.fmb module (Oracle Forms 9.0.2)
. Compile all and run the module
Par Oracle Forms community
-
Publié dans : Bean - Text items
0
-
Recommander
Vendredi 25 janvier 2008
5
25
/01
/2008
11:13
Purpose
Here is a Java Bean that allows sending back to the Forms application each key pressed in any Text Item.

The Java code
keypressed.java
The implementation class of the Bean Item
oracle.forms.fd.KeyPressed
The methods you can call
Initialize the bean
Set_Custom_Property('BLOCK.ITEM',1,'INIT','');
This method must be called in the When-New-Form-Instance. It is used to search for every Text Items in the
Forms to attach to them a key listener.
e.g.:
-- Init the bean --
Set_Custom_Property( 'BL.BEAN', 1, 'INIT', '' ) ;
The event fired by the JavaBean
KEY_PRESSED
It is constituted by 3 parameters to get the key code, the key char and the key modifier.
To know what text item has just fired the event, ask the :SYSTEM.CURSOR_ITEM variable.
When-Custom-Item-Event:
DECLARE
eventName varchar2(30) := :system.custom_item_event;
eventValues ParamList;
eventValueType number;
LC$Code varchar2(25); -- code
LC$Char varchar2(25); -- char
LC$Modif varchar2(25); -- modifier
BEGIN
IF (eventName='KEY_PRESSED') THEN
eventValues := get_parameter_list(:system.custom_item_event_parameters);
get_parameter_attr(eventValues,'KEY_CODE',eventValueType, LC$Code);
get_parameter_attr(eventValues,'KEY_CHAR',eventValueType, LC$Char);
get_parameter_attr(eventValues,'KEY_MODIFIER',eventValueType, LC$Modif);
:BL.RESULT := :System.cursor_item || ' Key pressed:'|| LC$Code || ' (' || LC$Char||') '||' modif:'||LC$Modif ;
Synchronize ;
END IF;
END;
The sample dialog
. Download the keypressed.zip file
. Unzip the file
. copy the keypressed.jar file in the <ORACLE_HOME>/forms/java directory
. Edit your /forms/server/formsweb.cfg file to add the keypressed.jar .
. Open the KEYPRESSED.fmb module (Oracle Forms 9.0.2)
. Compile all and run the module
Par Oracle Forms community
-
Publié dans : Bean - Text items
0
-
Recommander
Jeudi 26 février 2009
4
26
/02
/2009
14:11
Hafed Benteftifa has just released his FRITE - Forms Rich Text Editor - alowing the Oracle Forms application to edit HTML content.

This is just the kind of Java Bean, developers and end-users were waiting for years !
Don't waste any more time, run and get it !
Par Oracle Forms community
-
Publié dans : Bean - Text items
0
-
Recommander