-
-
Notifications
You must be signed in to change notification settings - Fork 497
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ImportPythonUDFS throws a run-time error '53' (xlwings 0.6.1) #323
Comments
Ok so let's solve this step by step. When you start a command prompt and type |
C:\Users\xyz\AppData\Local\Continuum\Anaconda2\python.exe |
Ok cool so is this the installation that you want to use with xlwings? if yes, then I would suggest to set |
Yes, this is the installation that I want to use. PYTHON_WIN is set back to "" |
OK, then I would suggest you run |
I did all the steps and reinstalled xlwings. All dlls are in the same folder as python.exe |
OK, so make sure you're using the latest version of the VBA module and try again? same error? |
Yes, I added again xlwings.bas file, and same error. |
When you go into the VBA module |
(Make sure you have the Immediate Window open |
It shows same error: "Run-time error '53' File not found: xlwings32.dll" |
If you type |
This is what i get when I type echo %path% C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\NVIDIA Corporation\Ph |
Looks good - For now 3 more suggestions:
|
Yermek, we found a possible cause in the difference of how we were compiling the dlls for ExcelPython vs. xlwings. Can you please try to replace the dlls that come with xlwings (next to python.exe) with the ones from the link (you should only need xlwings32.dll if you run it with 32-bit Excel)? If that solves your problem, we'll be fixing this with the next release. |
Wow! Now it works perfectly. I just replaced my 2 dll files with what you provided, and it worked. Thank you so much! |
Yesterday my colleague installed xlwings 0.6.1 by just entering "pip install xlwings" into Command Prompt, and UDFs worked without any errors. His computer, the version of Anaconda2 and Excel is the same as mine. What is the reason that was causing Run-time error on my computer but not his if we had the same xlwings32.dll file on both machines? |
Thanks for the feedback! This will be available with 0.6.2 then. The reason is that on some systems, the xlwings.dlls are not finding the correct version and bitness of the the Microsoft Visual C++ RuntimeDLLs. To fix that, they are now statically linked against C++ runtime. |
Oh, I see. Thank you for helping me out! |
No problem, thanks for reporting! |
Solved by PR #325 |
I have Anaconda2(32-bit) installed on my computer(Windows 7 Professional, 64-bit), and I am using Microsoft Excel 2010(32-bit). I used ExcelPython previously, and it worked fine. Then I updated everything to xlwings 0.6.1 and deleted ExcelPython because xlwings and ExcelPython merged.
I added necessary xlwings.bas file to VBA as a module. When I press Alt+F8 button, which brings up "Macro" pop-up window, "ImportPythonUDFs" macro appears in the list. However, when I press "Run" button, it throws me "Run-time error '53'" error saying "File not found: xlwings32.dll".
This is what I tried so far:
When I provided path to python.exe file in "PYTHON_WIN" field and executed "ImportPythonUDFs", this error message appeared: "Run-time error '1': Could not load xlwings32.dll from either of the following folders: C:\Users\xyz\AppData\Local\Continuum\Anaconda2, C:\Users\xyz\AppData\Local\Continuum"
I checked that my xlwings32.dll sits next to python.exe file. – Nomad 15 mins ago
I tried uninstalling xlwings from computer by "pip uninstall xlwings". Command Prompt says that xlwings was successfully uninstalled. However, when I want to reinstall xlwings by typing "pip install xlwings", Commad Prompt says "Requirement already satisfied". How is this possible if I just uninstalled xlwings entirely from my computer?
The text was updated successfully, but these errors were encountered: