graphics drawline - graph - inner lines not showing up?

R

Rich

Hello,

I am trying to draw a graph on a form. I can draw the box
using drawline, and bars inside the box using
drawrectangle, but when I try to draw a line inside the
box the inner lines are not showing up. Do I need to use
a property or something?

Here is the code for my lines

Graphics g = this.CreateGraphics();
Pen pen2 = new Pen(Color.Blue);

g.DrawLine(pen2, 30, 50, 300, 50); //horizontal top
g.DrawLine(pen2, 30, 50, 30, 190); //vertical left
g.DrawLine(pen2, 30, 190, 300, 190); //horizontal bottom
g.DrawLine(pen2, 300, 50, 300, 190); //vert right
g.DrawLine(pen2, 70, 50, 70, 190); //vertical inner

The vertical middle line is not showing up. Any
suggestions appreciated what I could do to make the inner
line show up.

Thanks
 

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