Downloading Alert when Opening a Workbook Programmatically

GohDiamond

"Access- Imagineer that!"
Local time
Today, 00:58
Joined
Nov 1, 2006
Messages
550
I have an issue when opening an excel workbook programmatically. I'm using MS Access 2013 on Windows 8.1


Code:
   [COLOR="Blue"]Dim [/COLOR]objExcel [COLOR="blue"]As[/COLOR] Excel.Application
   [COLOR="blue"]Dim [/COLOR]objSheet

   [COLOR="blue"]Set [/COLOR]objExcel = CreateObject("Excel.Application")
   objExcel.DisplayAlerts = False
   objExcel.ScreenUpdating = False

   objExcel.Workbooks.Open FName

   [COLOR="DarkGreen"]' do some formatting of the spreadsheet[/COLOR]

       objExcel.ActiveWorkbook.Save

   [COLOR="darkgreen"]' do the rest of the housekeeping and setting to nothing[/COLOR]

FNAME is the File Name that is passed to the function as a string. Only 1 specific workbook is open and formatted then saved and closed.

The workbook which is on the LAN is opened but the issue is a VISIBLE ALERT with the titlebar "Downloading" and body saying Downloading: filename....

EVENTHOUGH I have specifically told it NOT TO DISPLAY Alerts it still displays downloading and saving on objExcel.ActiveWorkbook.Save

Has anybody else had this issue in any version of Access and does anybody have any ideas as to how to get rid of these annoying popup alerts?

Thanks in advance for any assistance
Cheers,
Goh
 
The downloading is an Excel status message, not really an alert.
You could try the excel toggle to

ObjExcel.Application.DisplayAlerts = False
 
Makes perfect sense now that the popup was identified as the Excel APPLICATION's status display. I took the liberty of adding one more thing:

Code:
ObjExcel.Application.DisplayAlerts = False 
[COLOR="Blue"]ObjExcel.Application.DisplayStatusBar = False [/COLOR]

And as Bullwinkle says: "Presto!" (but this time it worked :) )

Thanks Ranman256

Cheers!
Goh
 

Users who are viewing this thread

Back
Top Bottom