[wxpython-users] where we put the .png files?

Christopher Barker Chris.Barker at noaa.gov
Fri May 2 11:06:46 PDT 2008


Tim van der Leeuw wrote:
> os.argv[0] gives you the full absolute path to your application. So
> you strip the filename off using functions from os.path module, and
> load the pictures and other files from the application directory (or
> subdirectory thereof). Works for me ;-)


Note that this is not reliable across all OSs, hence the need for 
wx.StandardPaths. It usually works fine on Windows, though.

-Chris


-- 
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker at noaa.gov



More information about the wxpython-users mailing list