Ask Your Question
0

Run program automation file

asked Jul 27 '17

YI-WEI gravatar image

updated Jul 27 '17

I want to use psse33 to excel and Run program automation file ,I choose psse33 "example" folder and choose file name: poutexcel.py . final, I see the output bar show some message: Import Error: DLL load failed: Can not find the specified module Couldn't open Python file:C:\Program Files (x86)\PTI\PSSE33\EXAMPLE\poutexcel.py

How to solve it ? thank!!

2 answers

Sort by » oldest newest most voted
0

answered Jul 27 '17

jconto gravatar image

To run a python code located in the "example" folder, open PSSe, load the "savnw.sav" case and then run the python script pout_excel.py.

When the error is related to: "Import Error: DLL load failed..." and for the above python code (lines 70 to 72):

import win32com.client      #<- win32com shall be installed by user during PSSe installation
import os                   #<- os is installed with python
import psspy                #<- psspy is installed with PSSe

My guess is that your PSSe/python installation does not have the module "win32com" installed. Re-install psse and make sure that the option to install "win32com" is checked.

link

Comments

I do your way but it is show error,your "win32com" is mean "Python Win32"?

YI-WEI gravatar imageYI-WEI (Jul 27 '17)

"win32com" is mean "Python Win32" Save the three lines of code above to a new file "test.py" and run it within PSSe . do you still get same error?

jconto gravatar imagejconto (Jul 27 '17)

" SyntaxError: invalid syntax Couldn't open Python file:C:\Users\S0131\Desktop\test.py " in psse output bar There may be the "Intel Runtime Libraries not found" problem? about the below I paste..

YI-WEI gravatar imageYI-WEI (Jul 28 '17)

I do not think it the "Intel Runtime Libraries not found" problem, since Visual Studio and Fortran are used for user-defined model needing compiling, but your case is a steady-state run. I suggest to re-install PSSe. If problems persists, contact PTI.

jconto gravatar imagejconto (Jul 28 '17)

OK! thanks a lot

YI-WEI gravatar imageYI-WEI (Jul 28 '17)
0

answered Jul 27 '17

YI-WEI gravatar image

updated Jul 28 '17

I paste my psse33install.log please help me check! [PSSE install log] C:\Program Files (x86)\PTI\PSSE33\PSSE330400Install.log

[Intel Runtime Libraries not found] An installation of the Intel Fortran compiler version 12 was not found. PSSE33 was built using IVF 12. At a minimum, the IVF 12 runtime libraries are needed to run PSSE33. The PSSE33 installer has copied IVF 12 runtime libraries to the PSSBIN folder. If the IVF version installed on your computer is later than IVF 12, run Environment Manager (EM) version 5.4 or later to copy latest IVF runtime libraries to the PSSBIN folder. If you are unsure of IVF versions insatlled on your computer, open EM. It provides a list IVF versions installed.

[PYTHON found] An installation of Python 2.7 was found. If you need to reinstall Python 2.7, download the PSS 33 prerequisite installer from: https://www.pti-us.com/pti/software/p...

[Python Win32 found] An installation of Python for Windows extensions was found. If you need to reinstall Python for Windows extensions, download the PSS33 prerequisite installer from: https://www.pti-us.com/pti/software/p...

[wxPython found] An installation of wxPython was found (wxPython2.8-unicode-py27is1). If you need to reinstall wxPython, download the PSS 33 prerequisite installer from: https://www.pti-us.com/pti/software/p...psse.cfm

[Common]

[Silent ENV] Running C:\Python27\Lib\site-packages\psseenvmanager\checkenvmgrpy27_silent.bat succeeded.

=================================================================================================== PSS(R)E Environment Manager Version 5.4 Fri Jul 28 17:33:50 2017

Setting up the environment for PSS(R)E operation and for creating PSS(R)E dynamics user models:

For normal PSSE use Fortran Compiler and Visual Studio are not required. Not having these programs installed, will not affect PSSE usage.

However, Fortran Compiler and Visual Studio are required for compiling/linking PSSE Dynamics User Models. If these programs are not installed and you plan to compile/link User Models refer to PSSE Support Web Page at: https://www.pti-us.com/pti/software/p... and follow link to "Compiler Information" for additional details.

PSSE versions installed: 33, 32

Error: Creating User DLL/LIB will fail for PSSE versions: 33, 32

Miscrosoft Visual Studio 2010 is installed, but encountered following error.

VS2010 default installation folder does not exist. Searched for C:\Program Files (x86)\Microsoft Visual Studio 10.0 installation folder: default

Miscrosoft Visual Studio 2008 is installed, but encountered following error.

VS2008 default installation folder does not exist. Searched for C:\Program Files (x86)\Microsoft Visual Studio 9.0 installation folder: default

Miscrosoft Visual Studio 2005 is installed, but encountered following error.

VS2005 default installation folder does not exist. Searched for C:\Program Files (x86)\Microsoft Visual Studio 8 installation folder: default

Fortran IVF 9.1 (or later) compiler is either not installed or Env Manager could not find it.

PSSE 33: Latest installed IVF version not found. IVF version value = None. Runtime DLLs not copied.

PSSE 32: Latest installed IVF version not found. IVF version value = None ... (more)

link

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.
Want to format code in your answer? Here is a one minute demo on Youtube

Add Answer

[hide preview]

Question Tools

1 follower

Stats

Asked: Jul 27 '17

Seen: 2,936 times

Last updated: Jul 28 '17