B
billq
Hello,
I have two custom control which will share a similar graphing function.
The graphing function needs to communicate back to the calling control
to gather information. I would like to send the control name via an
event handler to the graphing function and use the control name to
communicate with the correct control. I tried the following code
without success. any help would be greatly appreciated.
thanks
bill
private void OnLinearChanged()
{
SetUpTheGraph(userLinearPanelControl);
}
private void OnSinChanged()
{
// SetUpTheGraph(userSinPanelControl);
}
private void SetUpTheGraph(Control s)
{
s.SetRect(myGraphingPanel.ClientRectangle);
s.SetQueue();
myGraphingPanel.SetQ(s.GetQueue());
myGraphingPanel.Invalidate();
}
I have two custom control which will share a similar graphing function.
The graphing function needs to communicate back to the calling control
to gather information. I would like to send the control name via an
event handler to the graphing function and use the control name to
communicate with the correct control. I tried the following code
without success. any help would be greatly appreciated.
thanks
bill
private void OnLinearChanged()
{
SetUpTheGraph(userLinearPanelControl);
}
private void OnSinChanged()
{
// SetUpTheGraph(userSinPanelControl);
}
private void SetUpTheGraph(Control s)
{
s.SetRect(myGraphingPanel.ClientRectangle);
s.SetQueue();
myGraphingPanel.SetQ(s.GetQueue());
myGraphingPanel.Invalidate();
}