Auto Run

Some of you may know how auto run has been disabled in Windows 7 and so I was wondering if it is possible to make a c++ program that will enable auto run or something along those lines. I appreciate the help.
Control panel → AutoPlay (under Hardware and Sound if you are using Category view)
Last edited on
nvm I figured out how to do it using a batch file, if anyone else is interested here it is but in order for it to work you need to run it as admin because it edits the registry. I think MiiNiPaa's idea will also work but the registry is higher than the control panel so if autorun is disabled in the registry it wont work even if you enable it in the control panel.

Copy and pase to notepad, save as Whateveryouwant.bat and run as admin

@echo off
set key="HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer"
reg add %key% /v NoDriveTypeAutoRun /t REG_DWORD /d 145
Topic archived. No new replies allowed.