Drawing Graphics and ZOrder

G

Guest

Hi there,

I am writing an custom designer, and need a rubber band to select controls.
I am drawing the rubber band by using the Graphics object on the user control
where the other controls sit (hope that makes sense).

The rectangle object that I draw on the user control appears behind the
other child controls. Is there a way to force the graphics object to be
painted on top of the other controls?

Many thanks,

David.
 
R

Ronchese

In VB6 I was enabled to paint in Desktop (0), using API. It should work in
..Net also, but I dont remember where are my project that have that code.

Try search in Google by GetDesktopWindow and Rectangle APIs. Something like
that.

[]s
Cesar



"David Whitchurch-Bennett"
<[email protected]> escreveu na mensagem
Hi there,

I am writing an custom designer, and need a rubber band to select controls.
I am drawing the rubber band by using the Graphics object on the user
control
where the other controls sit (hope that makes sense).

The rectangle object that I draw on the user control appears behind the
other child controls. Is there a way to force the graphics object to be
painted on top of the other controls?

Many thanks,

David.
 

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