Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
CreateObject() vs. NewObject() functions
Message
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01367158
Message ID:
01367739
Views:
7
>>>>If FILE returns .F. it means that this file is not in the path. Verify the spelling of the classlibrary and that the file is where it is supposed to be.
>>>
>>>But then why would the first line (now commented out) work, I have just copy pasted for the messagebox()es
>>
>>1. Have you verified that the file exists where it is supposed to be?
>>
>>All other questions are irrelevant until this one is answered.
>
>
*loODBC           = NEWOBJECT("cODBC", "C:\VSO3\Common\Libs\cVSONoSCNonVisualUtilities.vcx")
>MESSAGEBOX(LOWER("C:\VSO3\Common\Libs\")$LOWER(SET("PATH")))
>MESSAGEBOX(FILE(UPPER("cVSONoSCNonVisualUtilities.vcx")))
>MESSAGEBOX(FILE("cvsonoscnonvisualutilities.vcx"))
>MESSAGEBOX(FILE("C:\VSO3\Common\Libs\cvsonoscnonvisualutilities.vcx"))
>MESSAGEBOX(FILE(LOWER("C:\VSO3\Common\Libs\cvsonoscnonvisualutilities.vcx")))
>MESSAGEBOX(FILE(UPPER("C:\VSO3\Common\Libs\cvsonoscnonvisualutilities.vcx")))
>loODBC           = NEWOBJECT("cODBC", "cVSONoSCNonVisualUtilities.vcx")
>
>.T. (folder name found in SET("PATH"))
>.F.
>.F.
>.T.
>.T.
>.T.
>then NEWOBJECT() fails.
>
>I have copied the name/pathname from explorer so there are no misleading letter-case for the last 4 MESSAGEBOX()es. Why does it not like the vcx name alone?

I think the problem may be with set path. Can you post the entire SET('path') statement or examine it closely. Try to set path to C:\VSO3\Common\Libs\ at the beginning of set path statement and see if this would make a difference.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform