Import Python UDF'S
Closed this issue · 6 comments
Hello,
i carefully followed the install instructions but unfortunately when I click on Import Python UDFs, I get run-time error 1000.
Could not create python process. Error message : File not found
Command:pythonw.exe -u
"D:\users\XXX\Desktop\TEST PY\xlpython\xlpyserver.py"
Do you know why?
Versions :
Excel 2010
Python 34
not succeed to install pywin32 but i installed pypiwin32 which seems to be similar.
Thank you for your precious help.
Hi N23K,
This probably means that pythonw.exe
isn't in the path for some reason. If you open up a command line and try typing pythonw.exe
does it give an error?
Regards,
Eric
Hi Eric,
Thank you very much for your answer.
You are right, it doesn't work.
I searched for this file on my hard disk but didn't find it.
Does it mean that the installation did not proceed correctly? I used the excelpython-2.0.9.exe file for installation.
Package is installed in the D:\Users\XXX\AppData\Roaming\Microsoft\Excel\XLSTART directory
Regards,
Nathanaël
It means that Python did not get installed properly.
The default configuration of ExcelPython expects pythonw.exe
to be on the system path. This condition is usually met after a normal installation of Python (or Anaconda or most other distributions).
If you are using some special Python installation, you will need to tell ExcelPython where to find either the python.exe
or pythonw.exe
executable, by editing the xlpython.cfg
file found in D:\users\XXX\Desktop\TEST PY\xlpython
.
Hi Eric,
Thank you very much for your help.
I think that this issue comes from the fact that python is installed on C:\Python34 whereas the ExcelPython module is installed and run on D:\users....
I would like to modify the xlpython.cfg as you suggested it but i don't know how to do. I have this command line when i open the file with the notepad.
Command = pythonw.exe -u "$(ConfigDir)\xlpyserver.py" $(CLSID)
Can i modify the line like that?
Command = C:\python34\pythonw.exe -u "$(ConfigDir)\xlpyserver.py" $(CLSID)
Thanks,
Nathanaël
Note that alternatively you could also add the path of pythonw.exe to your path, see: http://superuser.com/questions/143119/how-to-add-python-to-the-windows-path
Thanks a lot, it works now when i change the command line
Command = C:\python34\pythonw.exe -u "$(ConfigDir)\xlpyserver.py" $(CLSID)
I didn't add yet the pythonw.exe to the system variables, but i will try.
Thanks again !!!