Problem updating via macro

  • Thread starter Thread starter Erik
  • Start date Start date
E

Erik

Hi,

I have a macro that functioned fine in Excel 2000 but somehow is
different in 2003.
Now when trying to open the file to be updated is opened Read-Only and
subsequently cannot save automatically. When opening the workbook
manually it just opens.
Any clues would be greatly appreciated.

Thanks, Erik

Top part of the vba:
Sub Auto_open()
'
' Auto_open Macro
'
'
Application.DisplayAlerts = False


Workbooks.Open Filename:="\\NLxx\BI Office reports\040\COM\Sales
statistics IND.xls"
Sheets("Detailed").Select
ActiveSheet.PivotTables("PivotTable1").RefreshTable
ActiveWorkbook.Save
ActiveWindow.Close
 
You can try being more explict - although I don't know if that will help:

Workbooks.Open Filename:="\\NLxx\BI Office reports\040\COM\Sales
statistics IND.xls", ReadOnly:=False
 
Got it.. There was a share on top that apparantly in win2003 are
read-only by default.
Erik
 

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

Back
Top