Skip to main content

Disable autorun in Windows XP

Except for using gpedit.msc to disable the Autorun, here is the other procedure for creating a batch (.BAT) file that creates an AUTORUN.INF folder and disables the autorun feature in Windows.
  • Open Notepad. Click Start>Run, type NOTEPAD, then press Enter.
  • Copy and paste the following text in Notepad: 

 <@echo off :: SET_NO_DRIVE_OTORUN reg add HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer /v NoDriveTypeAutoRun /t REG_DWORD /d 0x0ff /f :: GET_DRIVES for /f "tokens=1 delims=:" %%j in ('reg query hklm\system\mounteddevices ^| findstr \DosDevices\') do ( echo %%j >> drives ) :: REMOVE_\DosDevices\_PREFIX for /f "tokens=3 delims=\" %%j in (drives) do ( echo %%j >> drives.txt ) del /q /f drives > nul :: REMOVE_SPACE for /f "tokens=1 delims= " %%j in (drives.txt) do ( echo %%j: >> drives ) del /q /f drives.txt > nul :: CHECK_DRIVE_TYPE for /f %%j in (drives) do ( fsutil fsinfo drivetype %%j | findstr "Fixed " >> fdtype fsutil fsinfo drivetype %%j | findstr "Removable " >> frtype ) del /q /f drives > nul :: GET_FDRIVES for /f "tokens=1* delims= " %%j in (fdtype frtype) do ( echo %%j >> dtype ) del /q /f fdtype > nul del /q /f frtype > nul :: REMOVE_SPACE1 for /f "tokens=1 delims= " %%j in (dtype) do ( echo %%j >> drives ) del /q /f dtype > nul :: DEL_DRIVE_A_FROM_LIST sort drives >> sort type sort | findstr "A" > nul if errorlevel 0 for /f "tokens=1 skip=1" %%j in (sort) do ( echo %%j >> sorted ) del /q /f drives > nul del /q /f sort > nul :: CREATE_OTORUN_FOLDER for /f %%j in (sorted) do ( md %%j\AUTORUN.INF attrib +s +h +r /d /s %%j\AUTORUN.INF ) del /q /f sorted > nul echo Press any key to close this window.. pause > nul>
    • Save the created file on your Desktop as the file DISABLE.BAT.
      • Locate the file on your desktop. Once located, double-click on the file.

        Popular posts from this blog

        Surabaya hits my mistress

        If this is your problem , i'm sure you are hit by a surabaya virus . My 1st pc that i treat as my mistress attacked by this virus when my brother connect it to a psp and these is what happens to my mistress: All folders and files including windows OS folder disappears. Only few folder files with fixed size of 40K appears to user. , When you try to change the options for show hidden files, it doesn’t show the previous data. , You will not able to run many anti virus & software programmes. Installation also get blocked. , There are files like thumb.exe , System becomes unresponsive. After login it takes lot of time to user to operate it. ...Can someone help me here!!!

        What is oDesk?

        If you are willing to work @ home online, try oDesk. Click this link