How to determine if a Python script is being run right after startup on Windows

Ryan George ragmanme at gmail.com
Tue Sep 7 01:19:46 EDT 2010


Hello!

I'm a newbie to Python (literally just started last Saturday), and I
coded a program that selects a random wallpaper from a directory and
swaps it with your current one (Windows only.)

What I'm looking to do is have it start up with Windows and
automatically swap the wallpapers. This part I have already coded, and
as far as I know, it should work. However, I want the user to be able
to access the GUI after this initial running of the program. The way
it is set up now, enabling "Start Up Mode" will cause the program to
cycle the wallpapers and then immediately exit.

My question is this: is there any way I can determine if the program
is being run directly after a startup on a Windows machine?

Thanks,
Ryan



More information about the Python-list mailing list