Oracle forms/Oracle Reports/Oracle /Oracle D2k/Oracle 2000 /Oracle 10G
Editor :- (Cnt+e)
1. this is used to show an editor user to enter information in a more comfortable way, used for fields like, address, comments, name etc
2. there are 3 type of editor
• default editor
• system defined editor
• user defined editor
DEFAULT EDITOR :- every text box is by default associated with a default editor
SYSTEM EDITOR :- in the property of text item we can use ‘system editor’ to show system editor at run time.
( who notepad/textpat/wordpad depending on what is editor that is associated with oracle in the file init.ora)
User defined editor :-
1. we can create our own editor and show it to user as per our requirement using a built in procedure i.e show_editor
Syntax
Show editor (‘name of editor’,message_in,x_pos,y-pos,message_out,Boolean_val,out parameter);
Out parameter will return true if user clicked ok on editor and false if user cancelled the
Editor.
Various ways to used editor at run time.
1.
2. edit menu :- edit on the text item.
3. Built in procedure:- ‘edit –texttem’ in the triggers
4. show_editor
Steps for create an editor.
1. create an editor
2. Make changes in the property of editor as per requirement.
3. Show editor using show editor/others ways at run time.
Code for editor button (when-button-pressed) of job field of emp block :-
Declare
B Boolean;
V_job varchar2(4000);
Begin
Show_editor
(‘ed_job’,:emp.job,100,100,v_job,b);
If b then
If length(v_job)>9 then
Message(‘you can enter 9 letter only’);
Message(‘’);
Raise form_trigger_failure;
Else
:emp.job := v_job;
End if;
Else
Message(‘cancelled’);
Message(‘’);
End if ;
End;
that is not clear please explain how???????
ReplyDeletePlease Be clear what is not clear...
ReplyDeleteThanks
Ankur GArg
Thanks.
ReplyDeleteVery useful