Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Property click is read only
Message
 
To
06/11/2000 15:53:25
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00438468
Message ID:
00438541
Views:
8
>Um, exactly what I thought would happen.
>
>Let me reiterate:
>
>This cannot be done at run time.
>
>Which means it cannot be done in a PRG in this fashion.
>The form (or class) must be up in the Form (or Class) Designer.
>
>>here is all my code in a prg:
>>zForm = CREATEOBJECT('Form')
>>zForm.AddObject('cmd1','CommandButton')
>>zForm.cmd1.Caption = 'Process call nbr' && Caption on the Command button
>
>Even if it could be done at run time, this line will not work, because of the "=" .
>
>>zForm.cmd1.writemethod=("click","thisform.release()")
>
>Here's a design time PRG that will work:
>
Modify Form myform Nowait
>ASelObj(lax,1)
>ZForm = lax[1]
>ZForm.AddObject("cmd1","commandbutton")
>ZForm.cmd1.Caption = "Release thisform"
><b>ZForm.cmd1.WriteMethod("Click","Release thisform")</b>
I guess I misunderstood you, and thought I could proceed by the writemethod code rather then "ZForm.cmd1.Click = "Release thisform". I am experimenting, not sure why folks do this programatically rather then the form designer.
PS you code doesn't quite work, there's a modi form statment in it
and 'lax' dopes not exist. Did it work for you?
"Build a man a fire, and he's warm for a day.
Set a man on fire, and he's warm for the rest of his life."
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform