Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Reflecting changes in multiple forms
Message
From
03/10/2006 08:05:59
 
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01158783
Message ID:
01158818
Views:
17
This message has been marked as a message which has helped to the initial question of the thread.
Hi,

if you don't want that Form1 knows of Form2 and vice versa, introduce a third component, a mediator. Each Form will give that mediator a reference to itself at creation and informs the mediator of important variable or field chages. The mediaor then takes the approriate steps, eg refreshes Form1 if Form2 reports a change of a setting on which Form1 depends.

So the mediator is a behaviour object knowing what trigger what. You may also let Forms bind to a certain event within the mediator, so that it the intelligence could also stay in the forms.

In this case of forms, you could put the mediator logic into your form handler, if you have one. In general a mediator is somthing like the moderator of a talk show, it's a design pattern.

Bye, Olaf.
Previous
Reply
Map
View

Click here to load this message in the networking platform