Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Cannot open main.fxp after compiling
Message
General information
Forum:
Visual FoxPro
Category:
ActiveVFP
Environment versions
Visual FoxPro:
VFP 9
Miscellaneous
Thread ID:
01070623
Message ID:
01070820
Views:
14
"CLEAR PROGRAM main" will not work the way you have things arranged. If an error occurs in "main" or any routine called by main, your CLEAR PROGRAM statement will not work for "main" if issued within the error handler. You need to set a flag in the error handler, let the stack unwind, and then test for the flag and issue the CLEAR PROGRAM if the flag indicates that such an action is appropriate.

>Thanks! AVFP has this architecture:
>
>ASP/ASP.NET
>|
>Proxystub.prg - subclasses ActiveVFP(so it uses the error handler from there),creates ActiveVFP objects, calls main.prg. has this code after main.prg is called:
>SET PROCEDURE TO
>CLEAR PROGRAM main
>|
>Main.prg - externally marked, main application code (this is the one that needs to be unloaded), uses ActiveVFP objects
>|
>Activevfp.prg - contains the various classes
>has this code in the error handler:
>SET PROCEDURE TO
>CLEAR PROGRAM main
>
>* main.prg is external so that it can simply be replaced on a live server when new code is introduced (sort of like asp.net)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform