Yeah I would msgbox the directory variable anyways to make sure it is populating correctly.

To verify the GetAttr function is working right, run this, you should only see "true1"[vba]Sub ReadOnlyTest()
MkDir "C:\rndm1"
MkDir "C:\rndm2"
SetAttr "C:\rndm1", vbReadOnly
If GetAttr("C:\rndm1") And vbReadOnly Then MsgBox "true1"
If GetAttr("C:\rndm2") And vbReadOnly Then MsgBox "true2"
SetAttr "C:\rndm1", vbNormal
RmDir "C:\rndm1"
RmDir "C:\rndm2"
End Sub[/vba]