[Gambas-user] Ideas?

Jussi Lahtinen jussi.lahtinen at ...626...
Thu Feb 10 20:02:39 CET 2011


Thanks!
Works perfectly!

Jussi


On Thu, Feb 10, 2011 at 19:32, Doriano Blengino <
doriano.blengino at ...1909...> wrote:

> Jussi Lahtinen ha scritto:
> > Hi!
> > Any ideas how to implement following?
> >
> > I need to make open forms to refresh when they get signal from main
> module.
> > User need to be freely open or close forms as like. So I don't know are
> they
> > valid objects or not.
> >
> > So, form should have some kind of event handler, and event should be able
> to
> > rise from module.
> >
> > Now I have timer to check if signal is given, but I'm sure there are
> better
> > way to do this.
> >
> Every time you open a form (i.e., in its form_open event handler) you
> could use something like:
>
>  ' in every "slave" form
>  DIM hObserver AS Observer
>  hObserver = NEW Observer(hT, FALSE) AS "mysignal"
>
> At this point, from the main form you can raise signals that will be
> catched by your opened forms:
>
>    ' in every "slave" form
>    public sub mysignal_refresh(...)
>    ...do what to do when a refresh signal is received
>
> In your main form, when you want to refresh the other slave forms, you
> issue:
>
>    raise refresh
>
> You can even use formal parameters, to pass data from main to slaves.
> Or you can define several types of events.
>
> This should work... let me know :-)
>
> Regards,
> Doriano
>
>
>
>
> ------------------------------------------------------------------------------
> The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
> Pinpoint memory and threading errors before they happen.
> Find and fix more than 250 security defects in the development cycle.
> Locate bottlenecks in serial and parallel code that limit performance.
> http://p.sf.net/sfu/intel-dev2devfeb
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
>



More information about the User mailing list