I have a Windows Forms Class MainGUI
I have declared
MainGUI maingui;
public System.Componen tModel.Containe r components = new Container();
in the Class
I call another class MediaDriver with the Constructor
class MediaDriver
{
....
Form maingui;
private System.Windows. Forms.TrackBar trackBar1;
private System.Windows. Forms.Timer timer1;
....
public MediaDriver(Lab el label1 , TrackBar trackBar1 , Form maingui)
{
....
this.timer1 = new
System.Windows. Forms.Timer(thi s.maingui.compo nents);
this.timer1.Ena bled = true;
this.timer1.Tic k += new System.EventHan dler(this.timer 1_Tick);
....
}
But i get an error
'System.Windows .Forms.Form' does not contain a definition for 'components'
How can I solve this? How can I add a Timer for the MainGUI form in the
Class MediaDriver?
I have declared
MainGUI maingui;
public System.Componen tModel.Containe r components = new Container();
in the Class
I call another class MediaDriver with the Constructor
class MediaDriver
{
....
Form maingui;
private System.Windows. Forms.TrackBar trackBar1;
private System.Windows. Forms.Timer timer1;
....
public MediaDriver(Lab el label1 , TrackBar trackBar1 , Form maingui)
{
....
this.timer1 = new
System.Windows. Forms.Timer(thi s.maingui.compo nents);
this.timer1.Ena bled = true;
this.timer1.Tic k += new System.EventHan dler(this.timer 1_Tick);
....
}
But i get an error
'System.Windows .Forms.Form' does not contain a definition for 'components'
How can I solve this? How can I add a Timer for the MainGUI form in the
Class MediaDriver?
Comment