Editing

nate100

Member
Say if I have a frame with 3 fields that are updatable at the same time.
The field that are updatable are 'Name' 'Dept' and 'Code'
if the user enters say "Accounting" for the Dept then I like to have Code default to "NC".

Please keep in mind that all fields are updatable at the same time.
One way I think may work is by having an editing statement but not sure how to create it.
If somebody can help me with this that would be appreciated.

Thank you.
 

daranroo7

New Member
This could be achieved wth triggers... Hope the below code helps...

def variable hdle as handle no-undo.

on go,enter anywhere do:
if frame-field = "dept" then do: /* where dept is the field name for the department field*/
assign hdle = self:handle.
do while hdle:screen-value = "Code" /*where code is the field name for the Code field*/
hdle = hdle:next-sibling.
end.
hdle = hdle:next-sibling.
assign hdle:screen-value = "NC"
end.
 
Top