Jump to content
  • Advertisement
Sign in to follow this  
simon10k

startup

This topic is 4808 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

How do I make a program add itself to the startup so it starts automatically when the computer is turn on?

Share this post


Link to post
Share on other sites
Advertisement
I assume we are talking about Windows.

There is a registry key:
\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\CurrentVersion\Run

Under that key you create a string value with the path to your executable as "value".
The "name" of the string should be the name of you application. (Or something similarly descriptive)

Share this post


Link to post
Share on other sites
The same registry key also exists under HKEY_CURRENT_USER (e.g. it only starts up for the installing user, not all users of the machine)...

BTW, I have no idea what you are planning to use this for (so maybe I miss your point, then just ignore me please), but I totally hate programs that use these keys. Why hide yourselve buried in the registry, instead of being in the start menu. Most of the time it's ad- or spyware that does this <yuck>.
Of course, if you have you're (honest) reasons, please use the registry key.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!