L
LB79
I have a workbook that runs a macro when it opens - this works fine bu
when i open this workbook through another excel workbook the Auto_Ope
doesnt run. The code in the linked workbook is below. Does anyone kno
what im doing wrong?
Private Sub CommandButton1_Click()
If Dir("C:\Workbook2.xls") <> "" Then
Workbooks.Open "C:\Workbook2.xls"
ElseIf Dir("C:\Workbook2.xls") <> "" Then
Workbooks.Open "C:\Workbook2.xls"
Else
Workbooks.Open "C:\Workbook2.xls"
End If
Application.ScreenUpdating = False
Windows("Workbook1.xls").Activate
Application.StatusBar = False
ActiveWindow.Close
End Su
when i open this workbook through another excel workbook the Auto_Ope
doesnt run. The code in the linked workbook is below. Does anyone kno
what im doing wrong?
Private Sub CommandButton1_Click()
If Dir("C:\Workbook2.xls") <> "" Then
Workbooks.Open "C:\Workbook2.xls"
ElseIf Dir("C:\Workbook2.xls") <> "" Then
Workbooks.Open "C:\Workbook2.xls"
Else
Workbooks.Open "C:\Workbook2.xls"
End If
Application.ScreenUpdating = False
Windows("Workbook1.xls").Activate
Application.StatusBar = False
ActiveWindow.Close
End Su