Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Unable to Create Object
Message
From
27/02/2008 12:17:09
Jay Johengen
Altamahaw-Ossipee, North Carolina, United States
 
 
To
27/02/2008 11:56:23
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Environment versions
Visual FoxPro:
VFP 8 SP1
Miscellaneous
Thread ID:
01296912
Message ID:
01296942
Views:
9
Ok, good advice. I'm now using this line but still getting an error.
=NEWOBJECT( 'oAddRec', 'GridAddRec','FM_BaseButtons.vcx' )
The error is that "c:\FMSDev_Sch\libs\FM_BaseButtons.vcx" does not exist. But I have verified that it does and that there is a SET CLASSLIB to it in my Main program. Why can't it find it?


>SET CLASSLIB is set to the right class library?
>
>FWIW, I prefer using NEWOBJECT instead of CREATEOBJECT because I can specify the class library to use in the same call. No confusion or side effect if the SET CLASSLIB get modified later.
>
>>I am removing the dependency on the WizBtns classes in our base classes. This appears to be the last thing to do.
>>
>>I have a custom class in the FM_BaseButtons library called GridAddRec. In the AddRec method of the FM_ButtonBar class I make this call:
>>
>>
>>oAddRec = CREATE("GridAddRec")
>>
>>
>>But it is unable to create it. If I have the WizBtns.vcx in my project, it works. I copied the custom class from there into FM_BaseButtons and made sure there were no references to WizBtns.
>>
>>Why would the CREATE not be able to find the GridAddRec class if it exists in the same library?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform