Hello all,
I've lurked around here for a while and learned a ton from everyone, but I can't see this issue anywhere. I've been running macros through Autoit for a while in a number of programs, but I'm having some issues with this one.
Func RunMacro()
Local $oExcel = _Excel_Open(False, False, False, False) ;Excel Program
Local $oWorkbook = _Excel_BookOpen($oExcel, "C:/Equity Helper/Scripts/calendarmacros.xlsm", Default, Default, True)
$oExcel.Run("calendarmacros.xlsm!Calendar")
EndFunc
When I run this bit of code everything works fine as long as the macro gets to finish. But the actual VBA calls two "Application.UserInput" fields, and if I cancel out of either the macro closes, and then AutoIt throws an error at--
$oExcel.(<---error throws here)Run("calendarmacros.xlsm!Calendar")
I don't want to use autoit for the user inputs if possible, it's just easier to get the data I need for the inputs from within the VBA environment, but I'm afraid that's what's causing the problem.