So my question is:
How would I make a c++ program that starts up when the user logs in to their account and views the desktop? Such as how MSN starts up automatically when the computers starts.
I already know about the Start Up folder method but I was looking more into the Registry way.
And ofc you can tell I don't really know much about Registry so with the code if you can explain it to me step by step, i'd really be thankful.
Thank you.
Never mind. Just goto Run, type regedit.
Goto HKCU\Software\Microsoft\Windows\CurrentVersion\Run
Create a new string value. Change its name to your app name and its value to your app path (.exe). Restart your computer and enjoy!
P.S.
Now all you need is to do that stuff in C++ programmatically.
Well I have I just don't know much about it.
I can't find HKCU, I see a folder called Software though.
Would it be possible if you could help me with the code?
Thanks.
So if I were to send someone a .exe file, technically they would also need the new .exe file which tells the registry save the first .exe file so it could start up when the computer starts up?
Yes, and no. When you install a new program, the installer (if needed) sets up the registry so that the program can be run at each startup. But that doesn't mean that the registry can be set up only by a third party software. Your own exe can do that. It all depends upon what you want.
Well I would like for my own .exe to place itself in the user's start up folder or in the registry. Can you help me with a code that would help me do that? Please and thank you.
Besides, if you don't know much about the Registry we probably shouldn't be helping you create a program that installs itself in a way that it runs on start-up. Even if it's not malicious code it could screw up a PC if you're not sure what you're doing.