Skip to content
View in the app

A better way to browse. Learn more.

MSFN

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

How to make a runonce for every new user

Featured Replies

Hi,

first of all, sorry if this topic has been seen already, but after a long search on the forum, i did not find my solution.

My cd is almost finished, except that i would like to apply a reg tweak for every new user created, and this even if the user is created 1 year later. I want that runs only once, and for the user entering its session for the first time.

So my question is how to make it simple ? I tryed to apply a runonce method, but it it does not work. It even does not launch any .cmd

I tryed to import in the DEFAULT USER, but did not work.

Any help woudl be appreciated.

Thx

Weeb,


Forget using runonce. Runonce is a machine setting (HKLM) - not a user setting. If there was a user level (HKCU) runonce registry location you could just load up a registry file during the cmdlines.txt phase of setup.

Just create a CMD script (batch file) to do all the things you want. At the very end of the batch file have it delete itsself (this is easy to do, and supprisingly - it works). Then, simply place this cmd file in the default user startup (%ALLUSERPROFILE%\..\Default User\Start Menu\Programs\Startup).

When new users logon for the first time they will get a copy of the batch file from the Default User profile. The batch file will run - and delete itsself - never to be seen by that user again. The same will happen for any new account logons to that PC. Just what you wanted.

And besides - batch files are a hell of alot easier than runonce entries

  • Author

@Nois3

thanks, i will give a try, but i am sure that was what i was looking for.

One more time, this forum rocks :) and thank you Nois3.

Weebs,

Keep in mind one thing when using this technique:

The cmd file will run under the users context. If the user does not have admin rights don't try and do something like install drivers, it will fail.

I have this working for every user but only for first login

reg load HKLM\Test c:\docume~1\defaul~1\ntuser.dat

reg add HKLM\Test\Software\Microsoft\Windows\CurrentVersion\RunOnce /V 01 /t REG_SZ /D "whatever command"

reg unload HKLM\Test

I add this during my build and as a user logs in they get however many commands I have defined to run.

R

Actually there is a Run, RunOnce, RunServices, and RunSericesOnce for HKCU.

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\RunOnce

You can apply a Run or a RunOnce to the HKEY_USERS\.DEFAULT

What i proposed will run once for each user and is included in the NTUSER.dat file. It has nothing to do with the default user HKCU config...

It allows commands to be run the first time a user logs into the machine (who dosent have a profile yet)

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.