• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1044
  • Last Modified:

Minimising workbook from VBA while userform displayed

Hi,

I am using a number of userforms under VBA to help enter data into an excel spreasheet (XP, Office 2003).
I would like to be able to minimize the workbook while the userform is displayed.

Is there a workbook method that does this?

Thanks

G
0
gbergsma
Asked:
gbergsma
  • 2
  • 2
1 Solution
 
Rory ArchibaldCommented:
You need to use the Window object, not the Workbook:
activewindow.WindowState = xlMinimized
Regards,
Rory
0
 
gbergsmaAuthor Commented:
That minimises the workbook OK, however I want to minimise the Excel window
0
 
Rory ArchibaldCommented:
You need to use:
Application.WindowState = xlMinimized
and then you need to show the form modelessly - i.e. use:
userform1.show false

Regards,
Rory
0
 
gbergsmaAuthor Commented:
That does the trick - thanks!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now