Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hi all,

 

I am trying to measure the size of a picture, when I enter x and y values, then a dot would display onto the picture, how can I do it?

Don't have to type me the code, since I know it will be a huge list of codes, can somebody maybe give me a direction on how to do it?

 

Thanks alot

 

PlayKid

Posted

What's "A picture"

 

Is it a picturebox?

 

Is it a Bitmap?

 

For a bitmap, you simply do

bitmapname.setpixel(X_Position,Y_position,color.red) 'or color.blue, or color. yellow, etc.  

 

For a picturebox, I'm not sure how you can just set one pixel. BUT. I know how you can draw a line, and you can draw a very, very, very short line.

 

dim pixboxG as graphics
picboxG = picturebox.creategraphics
picboxG.drawline(new pen(Color.black), Beginning_X_Position,Beginning_Y_Position,End_X_Pos,End_Y_Pos)

 

I hope that helps.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...