HolySanta
06-22-2006, 04:09 AM
Hi guys, I know this is a noob question coz I can't find any threat that can help me in this.
I had a picture box that I want to draw a ruler on it. I try something like the code below but it just can't works. The picturebox did not show any thing.
'This is to draw the line
picRuler.CreateGraphics.DrawLine(Pens.Black, 0, 0, 0, 5)
'This is to draw the string
picRuler.CreateGraphics.DrawString("Inches", myFont, 0, 0)
Maybe I left something out coz I when I tried to use form's creategraphics object, nothing come out in the font as well.
Please help.
I had a picture box that I want to draw a ruler on it. I try something like the code below but it just can't works. The picturebox did not show any thing.
'This is to draw the line
picRuler.CreateGraphics.DrawLine(Pens.Black, 0, 0, 0, 5)
'This is to draw the string
picRuler.CreateGraphics.DrawString("Inches", myFont, 0, 0)
Maybe I left something out coz I when I tried to use form's creategraphics object, nothing come out in the font as well.
Please help.