Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How filling a property with an objectreference at design
Message
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00168392
Message ID:
00168436
Views:
30
Thanks for your reply

>>I've created a property for my subclassed label thats called 'boundto'. This property shall reference to a textbox. However I don't know how to insert an object-reference into this property at designtime. Is this possible at all or do I have to continue with using macro-substitution?

>To assign the object reference
>This.BoundTo = Thisform.OtherTextField (or whatever the object name is).

This would mean, the code had to be placed in Form.Init or so, but I tried to keep code in my label-class. At the time, as I still don't want to use a macro-subst., I am using a 'for'-loop and access the control by comparing the 'this.boundto'-property with this.parent.controls(i).name This will offer me full reference-access. But there surely might be some better way.

Tom
Best Regards
-Tom

Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are,
by definition, not smart enough to debug it.

Oh, and BTW: 010101100100011001010000011110000101001001101111011000110110101101110011
Previous
Reply
Map
View

Click here to load this message in the networking platform