Automatic execution or AutoPlay is a special feature of Windows 10 which allows the user to quickly select a desired action for various types of media that you have connected or previously connected to your computer.
Essentially with autorun in Windows 10 you can set your OS to open your favorite image viewer when you insert a disc with photos or automatically launch a media player application for the drive containing media files.
You can go to automatic execution from Control Panel> Hardware & Sound> AutoPlay or from Settings> Devices> AutoPlay.
The above feature saves you time, as the required application starts automatically every time you connect your device or insert your disc.
After you set them up settings to auto-run whatever you want, going one step further you might want to back up your customizations in order to restore them later or move them to another user account or another Windows 10 PC. Here's how to do it you are doing.
Note: Because you are going to tamper with the registry, we recommend that you back it up just in case. See here how you can make this copy.
Step 1: Open Registry Editor and go to the following registry key.
HKEY_CURRENT_USER \ Software \ Microsoft \ Windows \ CurrentVersion \Explore\AutoplayHandlers\EventHandlersDefaultSelection
Step 2: Right click on the key AutoplayHandlers on the left and from the menu that will open select it Export.
Step 3: Specify the file name to be exported to the registry key, as well as the save folder (if you do not like the default one) and press the "Save" button
Step 4: Now, go to the key
HKEY_CURRENT_USER \ Software \ Microsoft \ Windows \ CurrentVersion \ Explorer \ AutoplayHandlers \ UserChosenExecuteHandlers
Step 5: Right click on the folder UserChosenExecuteHandlers and select Export from the context menu.
Step 6: Give the * .REG file a name, change the storage folder (if desired) and press the "Save" button.
Now, let's look at how to reset AutoPlay preferences in Windows 10.
To restore the AutoPlay options from the backup you just created, using the instructions above, double-click the * .REG files to import them into the registry. Then log out and log in to your user account. Alternatively, you can restart Windows 10.
It is so simple.