Hello guys,
My program would allow a user to tweak its calculations engine via certain controls: radio buttons, check boxes etc. The problem is, based on such settings, appropriate events would take place that would either improve my programs performance (by disabling certain dynamic GUI updates) or slow it down (dynamic GUI control's updates).
To disable those GUI components, an event has to be assigned to null.
How can I do that from another class?
This is in 1 class, how would i assign it to null from another class(where my GUI is)? Any hints, pls?
My program would allow a user to tweak its calculations engine via certain controls: radio buttons, check boxes etc. The problem is, based on such settings, appropriate events would take place that would either improve my programs performance (by disabling certain dynamic GUI updates) or slow it down (dynamic GUI control's updates).
To disable those GUI components, an event has to be assigned to null.
How can I do that from another class?
Code:
public delegate void StringSynch (string stringname);
Code:
public event StringSynch LogReportSynch;
Code:
//log reporter
if (dynamicLogOption == false)
{
LogReportSynch = null;
}
Code:
if (LogReportSynch != null)
{
LogReportSynch(stepByStep_reportString);
}
Comment