Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Get form boundary position with respect to screen...

Status
Not open for further replies.

lidds

Programmer
Jun 9, 2005
72
GB
I have a ScreenCapture class that allows me to capture the content of the screen by specifying a X Y value of the top left and X Y value of the bottom right corner of a rectangle. This all works fine, however the problem that I have is that I want to capture the content of a panel on a form, the panel obviously has a location X and Y which gives me the top left position and I can use the width and height propoerty of the panel to determine the bottom right position. The problem that I have is this obviously gives me location of the panel on the form and not the screen. The other problem that I have is that this form is a MidiChild for another form.

So basically what I want to know is how can I get the location of the panel but as a screen position?

I hope that makes sense...

Thanks in advance

Simon
 
Get the X Y of the main form then add to that the X Y of the child form. Then add the forms height to all of that. In theory that should get you the position you need.

-I hate Microsoft!
-Forever and always forward.
-My kingdom for a edit button!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top