Quantcast
Channel: West Wind Message Board Messages
Viewing all articles
Browse latest Browse all 10393

Re: Can't run xxxtest.prg

$
0
0
Re: Can't run xxxtest.prg
FoxInCloud
Re: Can't run xxxtest.prg
12/13/2011
05:43:00 AM
3DS0C98WA Show this entire thread in new window
From:
To:
Attachments:
None
After checking, we need to check the case when server is in \test folder.
Programs located in original application folder should work, as indicated in our how-to guide.
Thanks for your patience...
thn

Thierry:

Thanks for getting back to me. I'd really like to get this working.

I don't seem to have a set procedure without an additive statement. Let me list my code below. 'xxx' is replaced with 'mud'.

mudtest.prg ---

LPARAMETERS ; tuFormsLaunch,; tlHTMLcomment IF Pcount() = 0 CLEAR ALL LOCAL tuFormsLaunch, tlHTMLcomment s ENDIF AW() SET PATH TO Addbs(JustPath(Sys(16))) + 'Progs\' ADDITIVE SET PROCEDURE TO mudServer, mudSets ADDITIVE EXTERNAL FILE mudTest.forms RETURN awServerStart('mudServerTest', m.tuFormsLaunch, m.tlHTMLcomment) * =========================================== DEFINE CLASS mudServerTest AS mudServer OF mudServer.prg OLEPUBLIC cawServerIni = 'mudTest.ini' ENDDEFINE * ===========================================


mudserver.prg ---

DEFINE CLASS mudServer AS awServer OF awServer.prg cAppSetsLib = 'mudsets.prg' cAppSets = '' lAppSetsClass = .F. cawProcessClass = 'mudProcess' && AS awProcess OF awServer.prg uFormsLaunchAtStartup = '' wUserAnonymous = .NULL. wUserDemo = .NULL. cawAppHostClass = 'awAppHost' && AS awAppHost OF awAppHost.fxp cawAppConfigClass = 'awAppConfig' && AS awAppConfig OF awServer.prg cawHTMLGenClass = 'awHTMLgen' && AS awHTMLgen OF awHTML.prg cawAJAXClass = 'awAJAX' && AS awAJAX OF awServer.prg cawSessionClass = 'awSession' && AS awSession OF awServer.prg cawProcessSetsClass = 'awProcessSets' && AS awProcessSets OF awServer.prg cScriptMapExts = 'php,pl,vfp,fic,zip' wlUserTemp = .F. cLangUser = '' && [cLangUser()] * =========================================== ENDDEFINE && Class xxxServer * =========================================== * =========================================== DEFINE CLASS mudProcess AS awProcess OF awServer.prg * =========================================== * ------------------------------------------------------------ PROTECTED PROCEDURE wUserSet && {fr} Règle l'utilisateur courant {en} Sets current user LPARAMETERS ; twUser,; && {fr} Identifiant utilisateur pour l'application - {en} User ID for application tlTemp && [.F.] (cf. awServer.wlUserTemp) {fr} Cet identifiant est emprunté - {en} This user ID is impersonated #IF .F. && SAMPLE IMPLEMENTATION CODE START _Screen.AddProperty('myUserIDprop', m.twUser) _Screen.AddProperty('myUserRightsProp', myRights(m.twUser)) #ENDIF && SAMPLE IMPLEMENTATION CODE END DoDefault(m.twUser, m.tlTemp) && {fr} Toujours conserver cette instruction ! - {en} Always keep this instruction! * ------------------------------------------------------------ PROTECTED FUNCTION wUserGet && {fr} Donne à FoxInCloud l'identifiant de l'utilisateur courant {en} Indicates FoxInCloud current user's ID LPARAMETERS tlTemp && [.F.] (cf. awServer.wlUserTemp) {fr} Cet identifiant est emprunté - {en} This user ID is impersonated #IF .F. && SAMPLE CODE START RETURN _Screen.myUserIDprop #ENDIF && SAMPLE CODE END RETURN DoDefault(m.tlTemp) && {fr} Supprimer cette instruction si vous implémentez - {en} delete this instruction if you implement * == 1 == 1 == 1 == 1 == 1 == 1 == 1 == 1 == 1 == 1 == 1 == 1 == * ------------------------------------------------------------ PROTECTED FUNCTION wFormHTML_cMenu && {fr} Définition du menu (cf. xxxMenu.xls) {en} Menu definition (cf. xxxMenu.xls) LOCAL lcResult TEXT TO lcResult NOSHOW FLAGS 1 PRETEXT 7 ENDTEXT RETURN m.lcResult * ------------------------------------------------------------ PROTECTED FUNCTION wFormHTML_cHeader && {fr} En-tête du formulaire {en} Form header RETURN DoDefault() + Textmerge([<p></p>]) && {fr} Juste un exemple {en} Just a sample * ------------------------------------------------------------ PROTECTED FUNCTION wFormHTML_cFooter && {fr} Pied du formulaire {en} Form footer RETURN DoDefault() + Textmerge([<p></p>]) && {fr} Juste un exemple {en} Just a sample && {fr} Exemple 1 - {en} Sample 1 PROCEDURE SampleForm1 && http://localhost/mud/SampleForm1.mud * or http://localhost/mud/bin/wc.dll?FoxInCloud~SampleForm1 RETURN this.wFormStandardPage('SampleForm1.scx') PROCEDURE SampleForm2 && http://localhost/mud/SampleForm2.mud * or http://localhost/mud/bin/wc.dll?FoxInCloud~SampleForm2 RETURN this.wFormStandardPage('SampleForm2') PROCEDURE SampleForm3 && http://localhost/mud/SampleForm3.mud * or http://localhost/mud/bin/wc.dll?FoxInCloud~SampleForm3 RETURN this.wFormStandardPage('SampleForm3.scx', 1, .F.) PROCEDURE SampleForm4 && http://localhost/mud/SampleForm4.mud?parm1=value1&parm2=value2 * or http://localhost/mud/bin/wc.dll?FoxInCloud~SampleForm4 RETURN this.wFormStandardPage('SampleForm4.scx'; , Request.QueryString('parm1'); , Int(Val(Request.QueryString('parm2'))); ) ENDDEFINE && CLASS xxxProcess

mudsets.prg ---

SET CLASSLIB TO 'C:\Test\MSInCloud\Develop\mud.vcx' ADDITIVE SET PATH TO (Home(1) + 'Tools\AB\') ADDITIVE AB() && loads ab modules SET CLASSLIB TO 'C:\Test\MSInCloud\Develop\mud.vcx' ADDITIVE SET PATH TO (Home(1) + 'Tools\AB\') ADDITIVE AB() && loads ab modules ON ERROR DO errorhandler WITH ERROR( ), MESSAGE( ), MESSAGE(1), PROGRAM( ), LINENO( ) SET CPDIALOG OFF SET TALK OFF SET KEYCOMP TO WINDOWS SET STRICTDATE TO 0 SET CENTURY ON SET EXCLUSIVE OFF SET HELP TO helpfile\MudSlinghelp SET TOPIC ID TO 1 SET DELETED ON ON KEY LABEL F1 Help


That is all the code I'm using.

TIA.

BR


Hi Boyd,

Thanks for using the FoxInCloud section of wwThreads

1- Though you don't mention it, I guess you replaced 'xxx' by your application code ...
2- This is the code of xxxTest.prg:

LPARAMETERS ; tuFormsLaunch,; && [xxxServer.uFormsLaunchAtStartup] {en} Forms to launch at startup, .T. all tlHTMLcomment && [.F.] {en} Comment generated HTML && {en} tuFormsLaunch = .T. generates global styles sheet 'awDefaultAll.css' IF Pcount() = 0 CLEAR ALL && {en} useful during development LOCAL tuFormsLaunch, tlHTMLcomment && {en} CLEAR ALL released these variables ENDIF AW() && {en} Loads FoxInCloud resources SET PATH TO Addbs(JustPath(Sys(16))) + 'Progs\' ADDITIVE && {en} Replace 'Progs\' by the sub-folder in which you usually store your .prgs, where 'xxxEnv.prg' and 'xxxServer.prg' should reside SET PROCEDURE TO xxxServer, xxxSets ADDITIVE && {en} both these .prgs are automatically included to your project #IF File('xxxTest.forms') EXTERNAL FILE xxxTest.forms && {en} application forms generated with xxxServer.uFormsLaunchAtStartup = .T.; always keep included in project! #ENDIF RETURN awServerStart('xxxServerTest', m.tuFormsLaunch, m.tlHTMLcomment) && {en} Starts xxxServerTest in file mode

This instruction:

AW() && {en} Loads FoxInCloud resources

adds the procedure you mention to Set("PROCEDURE")

My best guess is that you probably have a SET PROCEDURE without ADDITIVE in between;
Otherwise cModuleInfo() and abSet class would be in scope.

HTH,
Thierry Nivelet
FoxInCloud

Hi:

I've been going through all the steps, I thought, meticulously. I've been foloowing directions from "Installing a Development FoxinCloud Application Server." I am now on Step A5 where I "DO <App folder>\xxxtest.prg."

When it his the statement:
RETURN awServerStart('xxxServerTest',m.tuFormsLaunch, m.tlHTMLcomment)
I get:
File 'cmoduleinfo.prg' does not exist
Followed by:
Cless Definition ABSET is not found

I cancel it there.

Any idea what I may be doing wrong?

TIA.

BR




Viewing all articles
Browse latest Browse all 10393

Trending Articles