Change write protection through Windows registry If you want to set the flash drive to read-only for everyone, in step 9, uncheck all boxes in the Allow column, except for the Read entry. Verify if the USB flash drive allows you to modify its contents now.
If the USB flash drive is still read-only after checking the Allow checkbox in step 9, repeat the steps and check the checkbox for the Full Control entry. To check if security permissions need to be changed, follow the steps below. The security permissions may be set so that all users only have Read permissions to files on the flash drive. If using DiskPart, as detailed above, does not work to clear the read-only attribute of a USB flash drive, the security permissions may need to be changed.
You can list the attributes of the disk with the command attributes disk.In this example, we want to work with disk 1, so the command is select disk 1. Select your USB flash drive with the select disk command.In this example, we know that Disk 1 is our USB flash drive because its size is listed as 14 GB. Use the size of the disk to determine which one is your USB flash drive. At the DISKPART> prompt, type list disk and press Enter.If you receive a User Account Control prompt asking you for permission to continue, click Yes.Press Windows key+ R to open the Run box.You can use the Windows DiskPart command-line utility to enable or disable read-only mode on your USB flash drive. Using DiskPart to change read-only settings This action effectively sets all files, and the device itself, to read-only mode. If your device has this switch, move it to the "Lock" position.
The write protection switch is useful for keeping the contents of your drive safe from malware when you need to view them on a public computer. Some USB flash drives have a write protection switch on the side or bottom.
Change security permissions in flash drive properties.Using DiskPart to change read-only settings.