TabPage

  • Thread starter Thread starter Thore Berntsen
  • Start date Start date
What you can do is add a new paint handler to the particular TabPage
control, e.g. in the form constructor:

public Form1()

{

//

// Required for Windows Form Designer support

//

InitializeComponent();

tabPage2.Paint += new PaintEventHandler(tabPage2_Paint);

}

The PaintEventHandler can look something like this (just add it as a member
to the Form's class:

private void tabPage2_Paint(object sender, PaintEventArgs pe)

{

Graphics gfx = pe.Graphics;

gfx.DrawLine(new Pen(Color.Gold), 10, 10, 100, 100);

}
 
It worked like a dream. Thank You!
Maarten Struys said:
What you can do is add a new paint handler to the particular TabPage
control, e.g. in the form constructor:

public Form1()

{

//

// Required for Windows Form Designer support

//

InitializeComponent();

tabPage2.Paint += new PaintEventHandler(tabPage2_Paint);

}

The PaintEventHandler can look something like this (just add it as a member
to the Form's class:

private void tabPage2_Paint(object sender, PaintEventArgs pe)

{

Graphics gfx = pe.Graphics;

gfx.DrawLine(new Pen(Color.Gold), 10, 10, 100, 100);

}


--
Regards,

Maarten Struys, eMVP
PTS Software bv
 
Back
Top