PDA

View Full Version : Events sequence



Quailco
2014-03-02, 16:59
It would seem that the Lianja event sequence is markedly different then VFP. Is this deliberate or something else.

barrymavin
2014-03-02, 20:56
Which events are you referring to in which classes.

Quailco
2014-03-03, 13:18
Not sure I can give you an accurate answer yet. The statement stems from looking at the handling of a form in VFP and running the same form in Lianja. The process is definitely executing in a different way but its a complex form with lots of changes to default methods as well as added methods so I am working on a simpler version to test. When I find something concrete I will pass it along.

However, My statement should have been a question, my I ask:

Has anyone seen evidence of or are there any known differences between VFP and Lianja regarding event sequence execution?

HankFay
2014-03-03, 20:24
With regard to forms, INIT comes before LOAD in Lianja.

So you won't have data available in the INIT, as that is what the LOAD does (the INIT creates the scaffolding, as it were).

I remember when the Fox team jumped through hoops making stubs of form objects available in LOAD -- they weren't supposed to be available then, but then developers found ways to do things with them if they were available for the objects were instantiated. Lianja's approach makes sense, in that the objects are there before the data. That does away with the need to pre-read the SCX/VCX to create the stubs that are invisibly put in place in VFP. Takes a little getting used to; but everything gets done in the end.

hth,

Hank

cyrilbaskir
2014-03-03, 22:20
With regard to forms, INIT comes before LOAD in Lianja.

So you won't have data available in the INIT, as that is what the LOAD does (the INIT creates the scaffolding, as it were).

I remember when the Fox team jumped through hoops making stubs of form objects available in LOAD -- they weren't supposed to be available then, but then developers found ways to do things with them if they were available for the objects were instantiated. Lianja's approach makes sense, in that the objects are there before the data. That does away with the need to pre-read the SCX/VCX to create the stubs that are invisibly put in place in VFP. Takes a little getting used to; but everything gets done in the end.

hth,

Hank

Hi Hank

It was that way. Barry said this has been changed to:
LOAD()
INIT()
ACTIVATE()

yvonne.milne
2014-03-04, 07:29
Hi Quailco,

The Class type is important here. If you have a VFP Custom class - e.g. you are running an imported scx as an scp - then the order is as Cyril says and load comes first (more here (http://www.lianja.com/community/showthread.php?1433-Sequence-of-Form-Events)).

If you are talking about the Lianja Object Model (LOM): Pages, Sections, Fields/Gadgets etc. then load follows init. You can see more details on other threads here:

http://www.lianja.com/community/showthread.php?1750-Page-Form-Load-Sequence-of-events

and

http://www.lianja.com/community/showthread.php?1409-Cursor-Adaptor-best-practices

Regards,

Yvonne