Im having a mare with this. I am trying to align a form with a picturebox and the screen below it. In short i want to clip the screen image that appears in the picture box. I know the only way to do this is use the copyfromscreen and to create an image that is then loaded in the picturebox using a timer or i suppose a form mouse move event.
Problem i am having is aligning the image that appears within the picture box (images scroll one way to the other). I have been playing with this for a while however what i cant do is align what i see through the picturebox and screen below (when i have managed it , its always offset. Here is my script:
gfx.CopyFromScreen(New Point(Me.Location.X + PictureBox1.Location.X - 4, Me.Location.Y + PictureBox1.Location.Y - 30), New Point(0, 0), pic.Size)
PictureBox1.Image = pic
Can someone point out where im going wrong?