Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Bindevent to a property
Message
 
 
To
08/04/2013 20:32:23
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01570434
Message ID:
01570449
Views:
46
>>>>Hi everybody,
>>>>I used BindEvent to bind certain event from some object to another event usually on the form's object.
>>>>Right now I have the following situation.
>>>>
>>>>I have a mover class. This class has Updated property which is set from the button's code and may be in other places.
>>>>
>>>>I need to be able to link that property (when it's set to true) to the form's InfoChanged method.
>>>>I am not sure how to do this.
>>>>Thanks a lot in advance.
>>>
>>>
>>>Of course you can use ProgrammaticEvent() and signal it directly. To use BindEvent(), you can signal off the change of that property.
>>>
>>>See the syntax in this example: Message ID:1158912
>>
>>Thanks, I have it working already, but thanks for this interesting message reference.
>
>
>I misunderstood. As a workaround, from the BindEvent() you can test the property and then simply call your InfoChanged method manually. Or, you can add a separate BindEvent() which is designed to only signal InfoChanged.

I think I know what is happening, but I am not sure how to handle the problem. In the InfoChanged method I only want to set lChangesMade property if Updated property of the mover is true. However, I am using the same InfoChanged method for everything else.

So, if I programmatically set updated property to false, I do not want to set the other property to true.

I guess the solution could be to use a different event handler for this property only.

Do you have other ideas?
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