Hyflex Posted September 16, 2015 Share Posted September 16, 2015 Hi Guys,I can't figure out why the latest version of AutoIt (ever since the rewrite of the excel) the Excel_BookOpen never works, I started from scratch using the example from: https://www.autoitscript.com/autoit3/docs/libfunctions/_Excel_BookOpen.htm but it never works...See the screenshot below:Anyone have any idea how to get this working?I'm on Windows 10 (same happens on Windows 7) 64bit using Excel 2013 64bit.Any advice would be welcome Link to comment Share on other sites More sharing options...
water Posted September 16, 2015 Share Posted September 16, 2015 Your @Scriptdir is "C:\"? On Windows 10? My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Hyflex Posted September 16, 2015 Author Share Posted September 16, 2015 Your @Scriptdir is "C:\"? On Windows 10?Yes, The script is in C:\OpenExcel.au3 and the Excel file is in C:\Excel.xlsmSee to the left of my screenshot Link to comment Share on other sites More sharing options...
water Posted September 16, 2015 Share Posted September 16, 2015 Which version of AutoIt do you run? My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Hyflex Posted September 16, 2015 Author Share Posted September 16, 2015 Which version of AutoIt do you run?The latest one from the website, which is 3.3.14.1 but it was happening on 3.3.14.0 Link to comment Share on other sites More sharing options...
Jfish Posted September 16, 2015 Share Posted September 16, 2015 (edited) Looks like the path in that example was modified .... missing "\" before the file name - line 11. My bad, I see it is at root ... Edited September 16, 2015 by Jfish Build your own poker game with AutoIt: pokerlogic.au3 | Learn To Program Using FREE Tools with AutoIt Link to comment Share on other sites More sharing options...
BrewManNH Posted September 16, 2015 Share Posted September 16, 2015 My advice to fix this would be to not have the document in the root of the C drive. This is a protected area and Windows doesn't like it when you try to access files in this location. If the script were run with admin privileges it might work, but if the user isn't an administrator on the computer it will fail every time. If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator Link to comment Share on other sites More sharing options...
water Posted September 16, 2015 Share Posted September 16, 2015 I suggest to run the unmodified example script. If it works then one of your modifications causes the problem My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Hyflex Posted September 16, 2015 Author Share Posted September 16, 2015 My advice to fix this would be to not have the document in the root of the C drive. This is a protected area and Windows doesn't like it when you try to access files in this location. If the script were run with admin privileges it might work, but if the user isn't an administrator on the computer it will fail every time.Already tried multiple locations, downloads, desktop, documents, c, other hard drives all do the same thing. UAC is disabled and it's an admin accountI suggest to run the unmodified example script. If it works then one of your modifications causes the problem I did, look at the screenshot, all i changed was the location of the file and it's an xlsm not xls Link to comment Share on other sites More sharing options...
BrewManNH Posted September 17, 2015 Share Posted September 17, 2015 Did you run the UNmodified script, with the original file?I ran the script using Excel 2013 and 2007, on Windows 7 and 10 and it worked for me. I don't have UAC turned off on either one though, but I am an admin on both machines. If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator Link to comment Share on other sites More sharing options...
water Posted September 17, 2015 Share Posted September 17, 2015 I'm sure the problem is being caused by either the location or the workbook itself. Please run the unmodified example script to make sure this assumption is correct. My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Hyflex Posted September 17, 2015 Author Share Posted September 17, 2015 (edited) Did you run the UNmodified script, with the original file?I ran the script using Excel 2013 and 2007, on Windows 7 and 10 and it worked for me. I don't have UAC turned off on either one though, but I am an admin on both machines. I'm sure the problem is being caused by either the location or the workbook itself. Please run the unmodified example script to make sure this assumption is correct. http://i.imgur.com/XEj3iyE.png Edited September 17, 2015 by Hyflex Link to comment Share on other sites More sharing options...
water Posted September 17, 2015 Share Posted September 17, 2015 Did you try? I know that it works! I tried. My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Hyflex Posted September 17, 2015 Author Share Posted September 17, 2015 Did you try? I know that it works! I tried.I went back and edited, because at first I didn't know where the examples were because I got them straight from online documentation.But yes, I tried and it still fails: http://i.imgur.com/XEj3iyE.png Link to comment Share on other sites More sharing options...
water Posted September 17, 2015 Share Posted September 17, 2015 The COM error code stands for:"The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))"I have never worked with a 64 bit version of Office.Could you add#AutoIt3Wrapper_UseX64=yat the top of your script and try again? My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Hyflex Posted September 17, 2015 Author Share Posted September 17, 2015 Still the same as far as I can see: Link to comment Share on other sites More sharing options...
water Posted September 17, 2015 Share Posted September 17, 2015 Some recent problems were caused by misbehaving Addons. Could you please disable all Addons and try again? My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Developers Jos Posted September 17, 2015 Developers Share Posted September 17, 2015 The COM error code stands for:"The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))"I have never worked with a 64 bit version of Office.Could you add#AutoIt3Wrapper_UseX64=yat the top of your script and try again?doubt that works when not run from the full scite4autoit3 version as i see msgbox errors displayed.jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Bert Posted September 17, 2015 Share Posted September 17, 2015 what happens if you create a excel fine with the script, close it, then have the script reopen it at the same location? If that file won't reopen then we know there is a problem that isn't AutoIt related. The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
Hyflex Posted September 17, 2015 Author Share Posted September 17, 2015 Some recent problems were caused by misbehaving Addons. Could you please disable all Addons and try again?I have no pluginsdoubt that works when not run from the full scite4autoit3 version as i see msgbox errors displayed.jos Tried both from scite and non both don't workwhat happens if you create a excel fine with the script, close it, then have the script reopen it at the same location? If that file won't reopen then we know there is a problem that isn't AutoIt related. I'm not sure how you mean. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now