Promoted Write event (OpenInsight Specific)
At 08 MAY 1999 01:03:32AM Barry Stevens wrote:
I have implemented an Alt/O - Alt/R.
In a promoted read event I set an @property with the control values of the previous record's window. (by using the 'old' current control values)
Now that all works great, but, I have just realised that I need to set the " 'old' current control values" in a promoted write event.
The problem I have is all the controls are cleared by the time the event is executed.
Any ideas on how to access the window controls as a promoted event, prior to the write clearing the values.
I would like to be able to do implement the Alt/O - Alt/R using window control values and not @record.
Barry
At 08 MAY 1999 12:26PM Don Bakke wrote:
Barry,
You need to create a promoted WRITE event that execute before the system does it's thing. It's all in the way you name the promoted event. Below is an example of a post-system promoted WRITE (which is what you have) and a pre-system promoted WRITE:
Post-System Promoted WRITE
APPNAME*WRITE..OIWIN*
Pre-System Promoted WRITE
APPNAME*WRITE.WINDOW.OIWIN*
dbakke@srpcs.com
At 08 MAY 1999 05:00PM Barry Stevens wrote:
Don
Awesome!. I didn't know that.
If I made all my events "pre-system" and in the event code, did a forward_event(Param…), would that work and give me pre-post system info.
Barry
At 08 MAY 1999 05:30PM Don Bakke wrote:
Barry,
Yes, however, all normal precautions still apply. First, if you use Forward_Event() then make sure you return 0 otherwise you cause the system event to re-run itself. Second, since the system will clear your form during its operation you should gather any information you need before calling Forward_Event() (i.e. getting the RECORD or ID property of @Window.)
dbakke@srpcs.com
At 08 MAY 1999 10:31PM Barry Stevens wrote:
I pre-empted your response and tried it on one event, appeared to work, implemented it on all, went crazy, changed it all back and created separate ssp for the read & write pre system events.
Appears now after reading your response that I had left the return 1 in the code. Ah well..at least I can see now what events have pre processing…so I will leave it that way.
Thanks for the help (Again…)
Barry