I want to set a Wordfile as ReadOnly at a certain time. I do this with the following code.
Dim aFile as string = "C:\FileName.doc"
File.SetAttributes(aFile, FileAttributes.ReadOnly) = FileAttributes.ReadOnly
The file is ReadOnly but it isn't visible anymore in my Directory. When I set the ReadOnly property to False, using VB.net Code, the file becomes visible.
Can someone tell me what's going on here.
Live fast, die young and leave a beautiful corpse behind.
Dim aFile as string = "C:\FileName.doc"
File.SetAttributes(aFile, FileAttributes.ReadOnly) = FileAttributes.ReadOnly
The file is ReadOnly but it isn't visible anymore in my Directory. When I set the ReadOnly property to False, using VB.net Code, the file becomes visible.
Can someone tell me what's going on here.
Live fast, die young and leave a beautiful corpse behind.