Select to view content in your preferred language

Pythonwin startup script

948
1
Jump to solution
12-23-2013 08:05 AM
RichardHughes3
Deactivated User
Hi,

I'm at work now and cannot remember how I selected a python script to run when I open Pythonwin.  The purpose is simply to import arcpy modules and python modules.  Through my training I learned how to do it in Windows by choosing the script path within the properties of the program somewhere.  I am unable to locate the resource I used, but think that it is somewhere in a book or webpage closeby.  My other thinking is that I have to set an environment variable or something to that effect. 

Does anyone know the process for selecting a python script to run at the startup of PythonWin? 

Thanks,

Richard
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
DavidWynne
Esri Contributor
Hi Richard,

I'm at work now and cannot remember how I selected a python script to run when I open Pythonwin.  The purpose is simply to import arcpy modules and python modules.  Through my training I learned how to do it in Windows by choosing the script path within the properties of the program somewhere.  I am unable to locate the resource I used, but think that it is somewhere in a book or webpage closeby.  My other thinking is that I have to set an environment variable or something to that effect. 

Does anyone know the process for selecting a python script to run at the startup of PythonWin? 


I believe you're thinking of PYTHONSTARTUP environment variable.  If you point this system environment to a .py file, it will run the .py for any interactive prompt (PythonWin or otherwise).

-Dave

View solution in original post

0 Kudos
1 Reply
DavidWynne
Esri Contributor
Hi Richard,

I'm at work now and cannot remember how I selected a python script to run when I open Pythonwin.  The purpose is simply to import arcpy modules and python modules.  Through my training I learned how to do it in Windows by choosing the script path within the properties of the program somewhere.  I am unable to locate the resource I used, but think that it is somewhere in a book or webpage closeby.  My other thinking is that I have to set an environment variable or something to that effect. 

Does anyone know the process for selecting a python script to run at the startup of PythonWin? 


I believe you're thinking of PYTHONSTARTUP environment variable.  If you point this system environment to a .py file, it will run the .py for any interactive prompt (PythonWin or otherwise).

-Dave
0 Kudos