By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,293 Members | 1,397 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,293 IT Pros & Developers. It's quick & easy.

borderless form resizing

P: n/a
Lee
Hi,

how can this be achieved? are there any examples anywhere?

thanks in advance
lee
Mar 4 '06 #1
Share this Question
Share on Google+
4 Replies


P: n/a
All resizable controlling is just hit testing. Tie into the mouse down
event of your form and get the mouse coordinates. Check to make sure
that the mouse down is within some range of the border (5, maybe 10
pixels). Make sure that it's just a mouse down and not a click. Then,
resize the form as the mouse moves while the mouse button is down. This
lets you have the click and drag resizing.

Let me know if this helps.

~ Justin Creasy
Immerge Technologies

Mar 5 '06 #2

P: n/a
Lee
Hi,

yes thanks I got it working, but now I have a problem with flickering, any
ideas?

lee

"JustinC" <ju***********@gmail.com> wrote in message
news:11**********************@u72g2000cwu.googlegr oups.com...
All resizable controlling is just hit testing. Tie into the mouse down
event of your form and get the mouse coordinates. Check to make sure
that the mouse down is within some range of the border (5, maybe 10
pixels). Make sure that it's just a mouse down and not a click. Then,
resize the form as the mouse moves while the mouse button is down. This
lets you have the click and drag resizing.

Let me know if this helps.

~ Justin Creasy
Immerge Technologies

Mar 5 '06 #3

P: n/a
Lee
whoaahhhh ive sorted it,

thanks
"Lee" <le*****@hotmail.com> wrote in message
news:Oq****************@TK2MSFTNGP10.phx.gbl...
Hi,

yes thanks I got it working, but now I have a problem with flickering, any
ideas?

lee

"JustinC" <ju***********@gmail.com> wrote in message
news:11**********************@u72g2000cwu.googlegr oups.com...
All resizable controlling is just hit testing. Tie into the mouse down
event of your form and get the mouse coordinates. Check to make sure
that the mouse down is within some range of the border (5, maybe 10
pixels). Make sure that it's just a mouse down and not a click. Then,
resize the form as the mouse moves while the mouse button is down. This
lets you have the click and drag resizing.

Let me know if this helps.

~ Justin Creasy
Immerge Technologies


Mar 5 '06 #4

P: n/a
"Lee" <le*****@hotmail.com> wrote in message
news:Oq****************@TK2MSFTNGP10.phx.gbl...
Hi,

yes thanks I got it working, but now I have a problem with flickering, any
ideas?


You could fool Windows into thinking you're clicking on a border with some
interop. Search Google for the terms SendMessage and WM_NCLBUTTONDOWN and
should be plenty of hits on how to do it. A lot of them will be for moving a
window, but just swap out HTCAPTION for the value you need (see WM_NCHITTEST
on MSDN for alternate values).
Mar 5 '06 #5

This discussion thread is closed

Replies have been disabled for this discussion.