i have removed the brackets on the all now and now i get this script error
script error: unknown or unexpected command []!
$DriveDefinition=Ltrim(Rtrim(SubStr($DriveDefinition,InStr($DriveDefinition,")+1)))