Excel crashes when opening file

ryland00

Board Regular
Joined
Jun 13, 2014
Messages
76
Hello,

I am very confused. My macro was working perfectly opening files and consolidating and now it crashes every time I try to run it on the first line of code.

Code:
Sub PerformAll()
Dim wbSource As Workbook
Dim wbDestination As Workbook
Dim wbSource2 As Workbook
Dim wbDestination2 As Workbook
Dim wbSource3 As Workbook
Dim wbDestination3 As Workbook
Dim wbSource4 As Workbook
Dim wbDestination4 As Workbook
Dim wbSource5 As Workbook
Dim wbDestination5 As Workbook
Dim wbSource6 As Workbook
Dim wbDestination6 As Workbook




Application.DisplayAlerts = False
Application.ScreenUpdating = False
Application.Calculation = xlCalculationManual




'open the source workbook and select the source sheet for India
Set wbSource = Workbooks.Open( _
    Filename:=Sheets("Internal Instructions").Range("C11").Value & "\INDIA Monthly Financial Report FY18 Sep-17.xlsm")


where c11 contains the path : C:\Users\rland\Desktop\Test



I just don't understand what changed! Any help would be great.

Thanks!
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
Or could it be the file you're trying to open - INDIA Monthly Financial Report FY18 Sep-17.xlsm - contains a Workbook_Open event that causes your macro to crash?

Cheers,

tonyyy
 
Upvote 0

Forum statistics

Threads
1,223,098
Messages
6,170,103
Members
452,302
Latest member
TaMere

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