I have this macro I made that will Format a sheet a certain way. Well I having a hard time explaining to people how to set it up so I made this new sheet that has a box when clicked will take the macro off the desktop and import it into this file I called Personal1.xls and save it in the Windows directory. Then the macro hides the file so it is always in the background and they can run the macro anytime they want. Well I can get it to work fine and all, but when the other lady does it at another site, she gets an error when she goes to exit Excel. The Macro runs fine on the computer and hides it and everything but when she goes to Exit she says she get some Compile Error. I was hoping someone might know what the problem is. Here is the code of how the the Macro Imports the other one:
Sub Import()
'
' Import Macro
' Macro recorded 3/11/2002 by Greg
'
'
ActiveWorkbook.SaveAs FileName:= _
"C:WindowsPersonal1.xls", FileFormat:= _
xlNormal, Password:="", WriteResPassword:="", ReadOnlyRecommended:=False _
, CreateBackup:=False
SendKeys "%{F11}", True
ActiveWorkbook.VBProject.VBComponents.Import "C:WINDOWSDesktopmodule3.bas"
SendKeys "%{F4}", True
SendKeys "%{W}", True
SendKeys "{H}", True
End Sub
Any help would be greatly appreciated. Thank you.
Greg
Sub Import()
'
' Import Macro
' Macro recorded 3/11/2002 by Greg
'
'
ActiveWorkbook.SaveAs FileName:= _
"C:WindowsPersonal1.xls", FileFormat:= _
xlNormal, Password:="", WriteResPassword:="", ReadOnlyRecommended:=False _
, CreateBackup:=False
SendKeys "%{F11}", True
ActiveWorkbook.VBProject.VBComponents.Import "C:WINDOWSDesktopmodule3.bas"
SendKeys "%{F4}", True
SendKeys "%{W}", True
SendKeys "{H}", True
End Sub
Any help would be greatly appreciated. Thank you.
Greg