Version 5 architecture

Topics: User Forum
Nov 11, 2010 at 8:19 PM

Hello Claude

I realize that AVFP ver 5.0 architecture uses only activevfp.dll and main.prg

I realize also, that you have excluded from the distribution files and the last documentation.

But, if I need to protect the main.prg code to avoid unauthorized intervention of the code, what could you suggest me to do?

Is there a way to use compiled .FXP Files?

Or instead to do the EXECSCRIPT for the MAIN.PRG (at proxystub) replace with a function Call ?

Regards and Thanks in advance.


Nov 11, 2010 at 9:01 PM
Edited Nov 11, 2010 at 9:02 PM

Well I would do the easiest which is just to "Do yourprg.fxp" from main.prg or even try execscript yourfxp (I'm not sure this works).  Did you already try that? 

You could get the source code (available here online) and modify proxystub.prg to do a "do yourmain.fxp" instead of ExecScript main.prg but that's alot more involved...

This is defintely possible.  It's just a matter of how you should do it.  Goods things are:  protect your code and it should be faster.  (PHP also has these sorts of options).  Downside is FXPs get locked - you can't just replace the code without having to re-cycle IIS.

Nov 11, 2010 at 9:46 PM

Thanks for your answer.

It seems that using FXP files is not feasible because it can't return back  lcHTMLout  to root program (proxystub.prg).

Instead I replaced the EXECSCRIPT of MAIN.PRG with my own function  lcHTMLout()= Dispatch() at proxystub.prg, and it works flawlessly!!

Now I can use the EXECSCRIPT for the development and testing, and change to a function call for production.

What a great product, now is efectively more stable

Congratulations again Claude.

Nov 11, 2010 at 10:25 PM

Excellent!  That's a great tip for easily switching between optimized production and development.