Jump to content
Sign in to follow this  

Curious as to where RunOnce runs from?

Recommended Posts


I created a small script that creates a dir and copies itself there, then adds a key to the RunOnce registry to start at boot.

But I also added an Unistall so that if it is run from any other place (than its installed Directory) it will ask if you want to remove all.

Now with Windows XP booted up (startmenu showing) it works perfect, if run from it's install directory it begins to run it's main function and skips the uninstall option:

If @ScriptFullPath <> "c:\RegOwner\XPChangeOwner.exe" Then

--misc script here for checking and unistalling


--the main script to change XP Data...............

and if run from other than ScriptPath (ie. CDROM) it offers to uninstall as it should.

Problem is that when i use the RunOnce reg key to start it, it then brings up the uninstall msgbox so it seems RunOnce doesn't really run it from the starting directory?

am very confused, any Ideas?

Share this post

Link to post
Share on other sites

Sorry all,

been up too long i guess, spent forever fighting with this and found an EndIF out of place it was actually showing me a second similar message.

Again, very sorry


am very confused, <__ yep i was !!


Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.