100% Noob question: how to dynamically resize the form?

mrlucid
10-11-2006, 01:58 PM
It's been a while since I've coded anything and I am working to improve an existing project. I would like the main window (form) of the application to change size based on user interaction...

First off... the program is a fixed window size. let's say 320x240... and when the user clicks on a button I want the window to resize to let's say 640x480.

i know this is a really stupid question and i should have been able to figure it out by now but I figured i could get input from others.

I tried:

If (user clicks on item) Then
Me.Size.Height = 480
Me.Size.Width = 640

with no luck as well as many other ways that i could think of.

any help would be greatly apreciated. :)

Gruff
10-11-2006, 02:08 PM
Did you notice the squiggles under the code? VB is trying to tell you something. :)

Me.Height = 480
Me.Width = 640
Is probably what you want.

~T

mrlucid
10-11-2006, 02:28 PM
i think i already tried that... but i will give it a shot as soon as i am back in front of my machine. i really hope that it is something that simple.

thanks again

mrlucid
10-11-2006, 04:54 PM
Awesome!!! It worked beautifully! And it was painless... Thanks dude!!

Gruff
10-11-2006, 05:18 PM
*High Five* (Yep Racoons have five digits too.) :)

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum