Excel for iMac wont run macros.
Posted on 2012-08-28
New iMac with Excel 2011 opens spreadsheet, but macros will not run. Work was created on Excel for Microsoft OS.
After opening, there is a splash screen that reads "This workbook contains macros. Do you want to disable macros before opening the file" We click Enable Macros. The file opens successfully and the data is available to view. New data can be input in the workbook, but if the macro button is pressed we get the "Compile error. Cant find project or library" message.
The macros also give us issues on Windows OS installs; however we have found that the fix is to add the MSCOMCT2.OCX file to the appropriate sys32 folder. We also need to be sure there is a valid date in the 'last record' created. The fix on the IOS system has not been as simple.
The iMac code that is first displayed in the debugger is below. The workbook is attached, but all client info has been deleted. This may have some effect on function of the macro, but it is sensitive information.
Compile error. Cant find project or library.
Private Sub UserForm_initialize()
Dim b As Integer
DTPicker1 = Date
DTPicker3 = Date
DTPicker4 = Date
'Sheet3.Visible = xlSheetVisible '(show sheet to make changes)
'Sheet4.Visible = xlSheetVisible '(show sheet to make changes)
If WorksheetFunction.CountA(Cells) > 0 Then
M = ActiveSheet.Cells.Find(what:="*", after:=[A1], _