Keep workbooks hidden when opening

doggo

Board Regular
Joined
Jan 22, 2004
Messages
115
I am trying to run a process in a workbook that involves opening several workbooks, getting some data from each workbook then closing and repeating until all files data has been retreived.

This is working well apart from the workbook is temporarily displayed in the task bar when it is opened. Here is my code:

Code:
dim wbSource as Workbook

              For i = 1 to 5
                     Application.ScreenUpdating = False
                     Application.EnableEvents = False
                     Set wbSource = Workbooks.Open(Filename:=strFile, UpdateLinks:=False, ReadOnly:=True)
                     Application.EnableEvents = True
                     wbSource.Windows(1).Visible = False

              next i

I have also tried using application.ShowWindowsInTaskbar = False but I still get an annoying flicker in the taskbar pane for excel. I know it's not a maasive problem but it would be nice for it to look professional[/code]
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.

Forum statistics

Threads
1,203,460
Messages
6,055,556
Members
444,797
Latest member
18ecooley

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
Back
Top