Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Assign UDF to documentFile property on an oleControl
Message
From
06/07/1998 14:21:56
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Title:
Assign UDF to documentFile property on an oleControl
Miscellaneous
Thread ID:
00114635
Message ID:
00114635
Views:
71
I'd like to call my own GetFile wrapper (?) function, called Get_File() when I create my Excel OleControl object. I've tried a UDF in the PRG, and in a class method. I can call GETFILE() fine. I can assign the UDF return to a public variable in the prg, and set documentfile = myPublicVar.

I don't want to use a public, but I will if I have to. Any suggestions?

TIA

DEFINE CLASS oleexcelObject as OLEControl
oleTypeAllowed = 0
OleClass ="excel.sheet.8"
height = 170
top = 0
left = 0
DocumentFile = GetFile() && This works, but file must exist
*!* DocumentFile = this.getFile() && "Date type is invalid for this property."
PROCEDURE get_file
LOCAL cf
cf = getFile('XLS')
IF NOT FILE( cf )
RETURN ""
ENDIF
RETURN cf
ENDDEFINE
Next
Reply
Map
View

Click here to load this message in the networking platform