Cim program for a Trigger

schafik007

New Member
Hello !
I have one issue , I hope that you can help me .
I'm creating a cim program for a trigger .
the problem is that the cim is not working normally (triggers are not working) .
do you have any idea about this problem .
Thanks in advance .
 

Serj HAMMER

Junior Racer
Does Your trigger out of scope?

Trigger must be persistent (run only) or defined (or created) in the same scope, where will be WAIT-FOR.

Does it solve Your problem?
And what is the 'cim program'? (I don't know...)
 

schafik007

New Member
In fact the problem is independent form the Cim .
I explain . I have one program (prg1) that contain conditions based on frame-field . When I try to run (Run prg1) this program in another one . these conditions don't work . (frame-field is always Empty ) .
Do you have any Idea what to do ?
Thanks
 

Serj HAMMER

Junior Racer
it@flude.co.uk are right

I agree with it@flude.co.uk.
It is very clear, schafik007, when You use input parameters.

As I understood, your program (prg1) exctly independent from calling progcedure. In this situation you define frame in prg1, write (i.e. define) triggers and use WAIT-FOR (or UPDATE). User put data to fields, you take this data.

If user must not put data at this procedure - remove all triggers and frames, take input parameters and make their processing.
 

schafik007

New Member
Serj ;
May be I don't get what you mean .But , In automatic load I need the controls to be done to input values ( just like if the user write it manually ) . The solution is to take all the triggers from prg1 and put them again in prg2 . but I want to know whether there is a better sollution .
thanks
 

Serj HAMMER

Junior Racer
Yes, it is better solution

It is better solution, because onlty this solution you can have.

1) WAIT-FOR in prg1 do not see frames, widgets and triggers in procedure prg2 (except persistent triggers)

2) i.e. You need put WAIT-FOR to prg2

3) In prg2, in addition to WAIT-FOR you must define triggers

4) How could you get values in prg2? You can pass it from prg1 as input parameters.

5) You will put values from input parameters to the widgets in prg2 and manually fire triggers (APPLY "LEAVE" or "VALUE-CHANGED") to all widgets.

As result - every widget gets its value, process it in trigger and will be ready to user input.

Does it solution? :)
 
Top