None of the solutions above change the READONLY status of folders and files but this PowerShell script does based on the following powershell commands.
Query the READONLY status of a folder (via the DirectoryInfo object)
$roStatus = $dirInfo.Attributes -match 'ReadOnly'
Change the READONLY status of a folder (via the DirectoryInfo object)