How to make the program itself run when you start Windows?
3 answers
Registry.
HKEY_CURRENT_USER\Software\microsoft\windows\currentversion\run\
<- add a string index with a path to your program.
You can, for example:
- Create a shortcut in the Startup group of the Start menu.
- Register in the registry branch
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run
orHKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run
, depending on the task. - Make your program a service.
UPD0. By the way, yes. Thank you @ karmadro4 for reminding. The first two options are rolled only if the user is logged in (this is all related to the winlogon process). For guaranteed auto-start, only service is suitable at system startup.
- oneIn fact, only the service version satisfies the literal condition of the task. - karmadro4
Well, since no one has suggested such an option, I will suggest. Create a task in Task Scheduler . As the start trigger, select "When the computer starts" (as I understand it, this is an important condition of the topic-starter), then the task will be completed before winlogon, and as the task itself - the desired program.
In this case, it is not necessary to make the program a service.
Shell_NotifyIcon
function. - karmadro4