There are many ways to autostart an application, but the easiest, most common and IMO best are:
- Put a shortcut in the autostart folder
- Add an autostart entry to the registry (Software\Microsoft\Windows\CurrentVersion\Run)
The end result is the same for both. I believe the registry way is executed earlier in the logon process than the startup way, but I am not certain. It does not make any difference for most cases anyway. I prefer the registry, but that is personal taste. You can create and delete the registry key or the shortcut programatically in your app.
With both options you can use either one setting for all users (All User startup folder, or under HKLM key in the registry) or user specific (user startup folder or under HKCR key).
In general it is better to use the per user options, because you can be certain to have writing privileges in those areas; and every user on the computer can have his/her own setting.
answered 2009-02-17T16:04:30.137