Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
EXECSCRIPT and (EXE) classlibs
Message
De
06/12/2004 16:08:15
 
 
À
06/12/2004 16:03:18
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
00967239
Message ID:
00967318
Vues:
14
>>>>>>>I have the following code that is executed in a EXECSCRIPT:
SET CLASSLIB TO MyClass IN MyExe.EXE ALIAS XXX1 ADDITIVE
.
>>>>>>>I consistently get a dialog wanting to locate the 'missing' classlib.
>>>>>>>I've tried specifying the full path of the .EX but still no joy.
>>>>>>>
>>>>>>>Any ideas?
>>>>>>>
>>>>>>>Thanks
>>>>>>
>>>>>>Jim, I don't see that at all. What else is in your EXECSCRIPT? Are you sure that MYCLASS is a .VCX class library, and not a class in the library (of some other name)?
>>>>>
>>>>>Sorry, Fred, I thought I had not sent this because it was only partial...
>>>>>
>>>>>What I get the needing the classlib located on is a subsequent CREATEOBJECT().
>>>>>The class *IS* in the SETted classlib of above yet it indicates cannot find C:\MyApp\MySource\MyClasses\Myclass1.vcx!
>>>>>
>>>>>The execscript is running 'under' an exe - I revise while in the exe, then I tell it to run it.
>>>>>The class in question *IS* in the SET classlib. However, the specific class is reasonably 'complex' with other classes, some in another classlib, used in it. I *do* have a set classlib for the other class too.
>>>>>
>>>>>I've tried a few things and it just won't work UNLESS I make the named class lib(s) available in the path or if I do LOCATE them when asked.
>>>>>
>>>>>Thanks for any ideas.
>>>>
>>>>Ah, now I see what you're saying. It appears to be fixed in VFP9, but in VFP8/SP1, it can't find the .EXE file.
>>>
>>>Thanks, Fred (and again sorry for the quick trigger on the first message).
>>>I really need it now, but VFP9 is MUCH better than never.
>>>I guess that you're surmising that it can't find the .EXE?
>>>
>>
>>I mis-spoke a bit. If you have the SET DEFAULT to the right location, or you include the path to the .EXE in your EXECSCRIPT code, or even do a SET PATH in the EXECSCRIPT code, it works fine, even in VFP8. Mine failed when I forgot to SET DEFAULT to the location of the .EXE file. So it works, even in VFP8/SP1. Not sure why you're seeing it not work, even if you specify a full pathname for your .EXE file.
>
>Hmmm, I'm in no position to go set the default or change the path out from under the main program. That's why I went the full path route (used sys(16,0).
>Perchance are you trying it without the "ALIAS"? I have to use the alias because the same 2 classlibs involved are also used by the .EXE.
>

No, I made sure I used the alias. What I did not try was to make sure it was using the classlib from the .EXE, it was in the same folder as the .EXE....

I just tried that and it worked just fine, it found the classlib when it only existed in the .EXE.
xx = "set classlib to fbt in c:\vfpstuff\testembeded.exe alias xyz additive"+CHR(13)+;
 "disp status"+CHR(13)+;
 "release ox"+CHR(13)+;
 "public ox"+CHR(13)+;
 "ox=CREATEOBJECT('mytextbox')"
EXECSCRIPT(xx)
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform