Date:  09/08/2009 04:24:37 PM Msg ID:  004023
From:  FoxWeb Support Thread:  004020
Subject:  Re: Hiding core codes in a .app?
You must release the object, clear the class and release the procedure in this order.
 

...

RELEASE oPortal

CLEAR CLASS PortalClass

RELEASE PROCEDURE "MyFxpPath"

 
FoxWeb Support Team
support@foxweb.com email
Sent by Ali Koumaiha on 09/08/2009 02:26:04 PM:
Excellent. Worked like a charm!

another question:
in my fwx script i have:

set procedure to
set procedure to (my fxp path) additive
oPortal = CreateObject("PortalClass")
..
..
release oPortal


however, when when i change the prg a little (i am still bulding it), and i try to compile it.. it won't let me override the fxp that is currently there..  FoxWeb seems to have it on a lock.

what's the best way to release it after each script?
Sent by FoxWeb Support on 09/08/2009 12:04:57 PM:
You can absolutely do what you are asking for (both the .app and .fxp solutions). In fact, you could even just deploy the .fxp files for your .fwx scripts too. Once compiled, the .fwx files are not necessary for operation of the server.
FoxWeb Support Team
support@foxweb.com email
Sent by Ali Koumaiha on 09/08/2009 11:44:37 AM:
Hello!

I have a client where im developing a web application for him that uses FoxWeb server 4.3

what i want to do, is move my "core" codes from the scripts and i want to put them in a non-visible to the eye type format.

so, i created a class, i called it PortalClass, put it in a prg and all is working fine now still.

In the fwx:

oPortal = CreateObject("PortalClass")
oPortal.CustNo = "CDS100"
oPortal.GetStoreBalance()
.... fwx script goes here...

however, PortalClass.prg is visible to him, and i do not want them to see it. 

can I turn PortalClass.prg into a PortalClass.app, or just an fxp?

Then, how can i call/init my classes inside the PortalClass.app from his fwx scripts without exposing my codes?

i hope i made sense in this post.