J
James Maeding
I am familiar with using My.Computer.FileSystem.GetDirectoryInfo to get folder attributes, see code below...
This does not work though for network drives on my companies system.
We use windows as our server, nothing exotic.
I looked at the security permissions and the "write" box for domain users was grey, but not checked.
This means read-only to me and sure enough, I cannot change the files.
Is there a different way to deal with permissions controlling read-write property of folders?
thanks
Public Function IsFldrReadOnly(ByVal path As String) As Boolean
Dim reader As System.IO.DirectoryInfo
reader = My.Computer.FileSystem.GetDirectoryInfo(path)
If (reader.Attributes And System.IO.FileAttributes.ReadOnly) > 0 Then
Return True
Else
Return False
End If
End Function
This does not work though for network drives on my companies system.
We use windows as our server, nothing exotic.
I looked at the security permissions and the "write" box for domain users was grey, but not checked.
This means read-only to me and sure enough, I cannot change the files.
Is there a different way to deal with permissions controlling read-write property of folders?
thanks
Public Function IsFldrReadOnly(ByVal path As String) As Boolean
Dim reader As System.IO.DirectoryInfo
reader = My.Computer.FileSystem.GetDirectoryInfo(path)
If (reader.Attributes And System.IO.FileAttributes.ReadOnly) > 0 Then
Return True
Else
Return False
End If
End Function