Making bootable pendrive is essential to install fresh operating system on your pc, installing operating system using cd/dvd is slower and there is also the problem of cd/dvd which wont work sometimes, sometimes your cd/dvd reader wont work. So it is preferable to use bootable pendrive to install Windows/Linux.
Here is an step by step guide to make bootable pendrive using cmd.
Step 1. press windows+r and type cmd and hit enter, it will open up your command prompt.(fig. 1)
Step 2. Now in command prompt type Diskpart and hit enter, it will ask for the administrator permissions simply click on yes.(fig. 2)
fig.2- type diskpart
Before proceeding further it is preferable and good to remove all your external drives like flash/pendrive because accidentally these drives can be formatted. Only one pendrive with minimum 4GB of space should be connected. Take the backup of your data in pendrive because all data will be deleted in formatting the pd.
Step 3. now type in the new window of cmd List Disk and hit enter. It will show all disks connected to you pc like disk 0, disk 1 and so on with status, size, free, etc. We can recognize the pendrive with size. Disk 0 will be the system disk and disk 1(with minimum size =4gb) will be most probably your pendrive. (fig. 3)
fig.3- type list disk
Step 4. now type Select Disk 1 and hit enter. It will select disk 1 for upcoming steps(fig. 4)
fig.4- type select disk 1
Step 5. now type Clean and hit enter again. It will erase all your data from pendrive.(fig. 5)
Step 6. type Create Partition Primary and hit enter. It will create primary partition in the pendrive.(fig. 6)
fig.6- create partition primary
step 7. now type Select Partition 1 and hit enter, it will select the partition created in the last step.(fig. 7)
fig.7-type select partition 1
step 8. now type Format Fs=Ntfs Quick and hit enter. It will quickly format your pd using ntfs file system.(fig. 8)
fig.8-type format fs=ntfs quick
step 9. Type Active and hit enter. It will make partition as Active for booting after restarting the computer. If this step is missed then computer will not boot from the pen drive.(fig. 9)
Now the pendrive has become bootable. Now you just need to copy the windows files from cd/dvd or from your pc directory to pendrive root directory. (fig. 10)
After copying files completed restart your pc. When BIOS screen appears press F12 key. It will show the options to boot from cd/dvd drive, hard drive, pendrive. Just scroll down to pendrive and hit enter, your system will boot from pen drive. Now you can install windows OS. Thats it. Enjoy