gtheys 0 Posted January 12, 2011 I tried: $sAddIn = "H:\prog\essxleqd.xla" $oExcel = ObjCreate("Excel.Application") $oExcel.Visible = 1 $oExcel.WorkBooks.Add $oAddIn = $oExcel.AddIns.Add($sAddIn) $oAddIn.Installed = True $oExcel.WorkBooks.Open("H:\Balance_Inquiry.xls") When I do: <code> Run('"c:\pathtoexcel\excel.exe" "c:\pathtoaddin\addin.xla"') </code> It will work. But I prefer the former solution because I need to different things in excel and this will be easier. Share this post Link to post Share on other sites
gtheys 0 Posted January 12, 2011 UPDATE: $sAddIn = "H:\prog\essxleqd.xla" $oExcel = ObjCreate("Excel.Application") $oExcel.Visible = 1 $oExcel.WorkBooks.Add $oAddIn = $oExcel.AddIns.Add($sAddIn) $oAddIn.Installed = False $oAddIn.Installed = True $oExcel.WorkBooks.Open("H:\Balance_Inquiry.xls") This seems to do the trick. Seems the first time when I ran the script it got installed and worked. Afterwards it didn't. Weird part is that even when it is installed it doesn't execute second time. So each time I have to do the False part... Maybe someone can explain or provide a more elegant solution. Share this post Link to post Share on other sites