How to draw line on Panel?

G

Guest

Hello Friends,
I am putting the code to draw the line in onPaint
event of Panel control but it's not working. Can anybody help me how to draw
line on Panels in .Net compact framework 1.0?

Here is my code snippest to draw line -

void panel1_Paint(object sender, PaintEventArgs e)
{
Pen p = new Pen(Color.Black);
e.Graphics.DrawLine(p, 0, 30, 240, 30);
p.Dispose();
}

Thanks in advance

Santosh
 
G

Guest

Thanks. I got the fix of issue by myself. I am using now tabpage onpaint and
it's working.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top