Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How can I hack/modify methods column of vcx?
Message
From
17/04/2002 21:53:09
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Title:
How can I hack/modify methods column of vcx?
Miscellaneous
Thread ID:
00646138
Message ID:
00646138
Views:
55
I have a large class library, with mostly subclassed base controls. I have now decided that I want each control to have refresh method that says:
this.enabled=!thisform.editmode
Right now there are no other methods in any of the controls.
I issued:
browse fields uniqueid, parent=parent, objname=objname, user=user, methods=methods FREEZE METHODS for uniqueid <> 'RESERVED'
replace all methods with 'PROCEDURE REFRESH' + CHR(13) + CHR(10) + 'this.enabled=!thisform.editmode'+ CHR(13)+CHR(10)+'ENDPROC' + CHR(12) FOR NOT EMPTY(USER)
(I had tagged the user field with an x for controls where i wanted the method to be)

This seems to work. But I just got lucky I think. I need a systematic way of changing a set of methods across an entire library. I don't really know the vcx structure that well. Chr(13)+chr(10) at the last line gave me funky chars, so I tried chr(12) by itself, which worked, but, I'm not sure why. I don't know if this will work if I add other methods. Like replace methods with methods + , or if I want to delete a method issue a strtran or stuff.

TIA
Next
Reply
Map
View

Click here to load this message in the networking platform