USERFORM SIZE

neilp

Well-known Member
Joined
Jul 5, 2004
Messages
522
Office Version
  1. 365
Platform
  1. Windows
Hi guys

I'm sure this is an easy question, but is there a bit of code that will determine the size of the userform. I would normally just drag the form to the correct size, but I am looking at having a command button that when pressed will cause the userform to increase in size

Hope this makes sense

Cheers in advance

Neil
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.

tmcfadden

Board Regular
Joined
Aug 17, 2005
Messages
151
So, you would have two command buttons perhaps. The first one shows the form (non-modal).

The second one simply calls a macro with something like:
Userform1.Height = 100
Userform2.Width = 200

You might want to check to see if the userform is visible.

-Tim
 

neilp

Well-known Member
Joined
Jul 5, 2004
Messages
522
Office Version
  1. 365
Platform
  1. Windows
cheers Tim

that has given me all the info I need. Obviously you meant userform1 not 2 in the second line :p

thanks again

n
 

Forum statistics

Threads
1,175,647
Messages
5,898,635
Members
434,719
Latest member
JoC

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top