|
-
September 30th, 2009, 05:11 AM
#1
Registry vs Startup menu
Hi,
I want to run my application right after user login. When I put a shortcut to my application at the startup menu (Start>All Programs>Startup) the app ran perfectly. When I put it in the registry,
(I've tried both HKCU and HKLM - Software\Microsoft\Windows\CurrentVersion\Run), the app crashes.
Any ideas how to continue from here? What is the difference between the two?
Thanks,
aperfectpoint
-
October 6th, 2009, 02:02 PM
#2
Re: Registry vs Startup menu
It shouldn't matter unless you have some weird dependancy, "Run" key registry entries "In General" start before the Startup Programs folder is processed, but that can by changed or bypassed.
There are really about 10 places that programs can be automatically started, but you really don't need to know them, and should never use them unless you know exactly why you are (in which case, you know the keys).
Personally, I block 100% of everything that tries to put 'Startup' programs in the registry. Put them in the folder, or don't bother.
Oh, None of the registry "Run" keys (of any user flavor) will be read at all in safe mode, I'm not certain about the startup folder.
If your program crashes from one, and not the other, simply put, you have a bug, or are trying to initialize something before a dependency is met, and you aren't handling it properly.
-
October 6th, 2009, 02:48 PM
#3
Re: Registry vs Startup menu
Hi, rdrast
I'm new to this forum... sorry for barging in here, but I cannot seem to figure out how to start a thread on this forum! Can you please give me a clue!
Best regards and please forgive the intrusion APerfectPoint...
DKean
-
October 8th, 2009, 09:17 PM
#4
Re: Registry vs Startup menu
I've seen an XP machine (today) that was so infected that task manager was disabled in SAFE MODE. There was also a program RUNNING in the task bar that couldn't be stopped. Did a slow format, and it's doing fine now.
-
October 11th, 2009, 08:34 AM
#5
Re: Registry vs Startup menu
Thanx rdrast.
You are saying that I might mishandle the dependency, which must be the problem, since I don't have any bugs... (Kiddin' of course, but in this case I think it is more likely). How do I manage the dependency, from both within the code and within the registry? I noticed that when I run it from the Startup folder, the Pid it gets is rather high, and when I (try to) run it from the registry, it gets a pretty low pid. Is this related? How can I heighten (is this the correct term?) the pid?
Thanks
-
October 26th, 2009, 08:23 AM
#6
Re: Registry vs Startup menu
I don't know your program. It could be any dependency, that is not properly trapped.
For example, under Windows XP, the network might not actually be started until long after the user is logged in, and the desktop is up. There are ways to control this, and force the network to be initialized even before the Login prompt, but that is often disabled to speed up the boot process.
What if your program is relying on network services, and they are not available? Do you wait? Do you crash? Do you abort? That is all in your program. All dependencies are.
And why do you even care what the PID is? It doesn't matter in the slightest.
-
October 26th, 2009, 08:41 AM
#7
Re: Registry vs Startup menu
More importantly, what OS are you using ¿
-
October 29th, 2009, 01:01 AM
#8
Re: Registry vs Startup menu
PID's are assigned based on what level the process is running UNDER. User, System, etc
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|