[Gambas-user] Q) re:listeners/notification

richard terry rterry at ...1946...
Wed Jun 17 10:35:35 CEST 2009


Not sure what this would be called in gambas but I need to know how to do 
something like this.

My main clinical form as on its toolbar a columnview containing a list of 
reminders or recalls due for the patients, so that it is visually available 
to the user at all times.

The actual recalls can be entered from a number of different places in the 
program - either when the recalls module is loaded, or when patholgy results 
are read,[ or potentially by another user in another room down the track]

ie. The columnview needs to know when it needs to update its information on 
the basis of what is happening in another part of the program

So, I wondered how to set up a 'listener' or a 'notifier' or whatever you 
might call it.

at the moment, I do it in  a rather crude way like this.

when the clinical form loads, I set as a global variable

modglobal.ClinicalForm = Fclinical

So, when the recalls module is loaded, accessing the controls to update them 
is easy

modglobal.clinicaForm.cvwRecalls.Add() or whatever.

Any comments/suggestions. This is obviously a simplistic scenario, as another 
user could be in another room or half way across the planet accessing the 
same patients record!

Regards

Richard




More information about the User mailing list