HELP: Application.Visible issue - only hide workbook that has user

S

sam

Hi All,

I have a very critical issue with launching userform created in excel.

I have a like of code that says

Application.visible = false

I want to hide the workbook that has the userform only. But it hides all the
other opened workbooks too.. Is there a way to overcome this? There have been
users who had not saved their workbooks and launched the form and all their
excel files were gone.. How can I resolve this?

Thanks in advance
 
P

Patrick Molloy

application invisible is exactly that . Excel is hidden, the other workbooks
still exist.
your userform should ensure that the application becomes visible again when
it closes.
 
P

Patrick Molloy

to hide ONLY the workbook that runs the userform , use

Windows(ThisWorkbook.Name).Visible = False
 
S

sam

Thanks for the help Patrick, Is there a way to keep the workbook closed when
we pull data from it? or atleast keep it hidden?

For eg: In my form I have some fields that are auto populated from a
workbook that is on network drive based on what you input in certain fields..
Rite now I have it working but the workbook that has the information always
opens when my code pulls information from it. Is there a way to keep it
closed or hidden? I am not updating this workbook, just pulling information
from it.

Thanks in advance
 
P

Patrick Molloy

try
Application.ScreenUpdating=FALSE
before yo access the data. when you close the book, you can set this back to
tru
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top