Can user resize a userform or minimize/maximize it at run-time? 
Author Message
 Can user resize a userform or minimize/maximize it at run-time?

Is there a property that allows a user to either resize a form to make it
smaller or alternately to minimize or maximize? using Word 97/2000 windows.
I know you can make a form non-modal, but I haven't seen any other setting
that would allow a user interacting with the form to resize or
minimize/maximize it.

Thanks,

Ben



Mon, 06 Jan 2003 03:00:00 GMT  
 Can user resize a userform or minimize/maximize it at run-time?
Hi Ben,

VBA UserForms are intended to be non-resizable and non-minimizable. There
are no facilities within Word VBA to make UserForms anything other than
fixed size. In theory, if you knew enough Windows API programming, you could
find a way of subclassing the form and intercepting the stream of Windows
messages relating to the form, and trick it into being resizable. I've seen
presentations (albeit under VB rather than VBA) that show how to do this,
but I've not tried myself.

However, if you know enough about VB and Windows API programming to be able
to do this, you would also realise that it would be far less effort to write
your application as a COM add-in using VB6, where you can have resizable
forms from the start!

Regards
Jonathan West - Word MVP
MultiLinker - Automated generation of hyperlinks in Word
Conversion to PDF & HTML
http://www.multilinker.com
Word FAQs at http://www.multilinker.com/wordfaq
Please post any follow-up in the newsgroup. I do not reply to Word questions
by email

Quote:

>Is there a property that allows a user to either resize a form to make it
>smaller or alternately to minimize or maximize? using Word 97/2000 windows.
>I know you can make a form non-modal, but I haven't seen any other setting
>that would allow a user interacting with the form to resize or
>minimize/maximize it.

>Thanks,

>Ben



Mon, 06 Jan 2003 03:00:00 GMT  
 Can user resize a userform or minimize/maximize it at run-time?

Quote:
> However, if you know enough about VB and Windows API programming to be
able
> to do this, you would also realise that it would be far less effort to
write
> your application as a COM add-in using VB6, where you can have resizable
> forms from the start!

Thanks again Jonathan!

Helpful as always.

Ben



Mon, 06 Jan 2003 03:00:00 GMT  
 Can user resize a userform or minimize/maximize it at run-time?
I  don't know if this helps, but there is a "Zoom" property for Word VBA
forms that lets you scale the form (fit more on the screen), and I know
there's a class module available that does the API call to resize to your
current resolution.

Also -- you can hide and show forms instead of minimizing/maximizing, which
can be a helpful runtime alternative to minimizing/maximizing, since you can
keep the form loaded.

-Bill


Quote:
> Is there a property that allows a user to either resize a form to make it
> smaller or alternately to minimize or maximize? using Word 97/2000
windows.
> I know you can make a form non-modal, but I haven't seen any other setting
> that would allow a user interacting with the form to resize or
> minimize/maximize it.

> Thanks,

> Ben



Wed, 08 Jan 2003 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. How to disable minimize/maximize/resize on an MDI Form

2. Disabling Minimize/Maximize/Resize on MDIForm?

3. form minimize/maximize at runtime

4. How to minimize a window at run-time?

5. Newbie Q: Form focus to minimize at run time

6. possible to allow user to minimize/resize userforms in Word?

7. getting run-time behavior of a contained control in a user control at design time

8. How to hide the minimize, restore and close button on a maximized form

9. Hide Close, Minimize and Maximize at top of access window

10. Word 2000 minimize, maximize, close buttons

11. Program Memory - Minimized/Maximized

12. Minimize or Maximize Event?

 

 
Powered by phpBB® Forum Software