I have deleted a USB disk using GParted. I am trying to create a new disk using the unallocated space, and I found this message.
Can't write to /dev/sdb, because it is opened read-only.

I have deleted a USB disk using GParted. I am trying to create a new disk using the unallocated space, and I found this message.
Can't write to /dev/sdb, because it is opened read-only.

Run the following commands:
sudo hdparm -r0 /dev/sdb
sudo umount /dev/sdb
Then go to Gparted and format the drive as FAT32.
Now it can be opened by Windows or any other operating system.