Click here to Skip to main content
15,898,588 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am saving a wav file but cannot figure out how to save it so the attributes are read only.

VB
Dim formatteddate As String
       formatteddate = DateTime.Now.ToString("MMM" & "-" & "dd" & "-" & "yyyy" & "-" & "HHmm" & "-" & "ss")
       Dim Filetosave As String = "save recsound " & ("\\bsppd4wiswalld" & "\Recordings" & "\" & formatteddate & ".wav")
       mciSendString(Filetosave, "", 0, 0)
Posted

VB
System.IO.File.SetAttributes(Filetosave, IO.FileAttributes.ReadOnly)
 
Share this answer
 
can't get that to work. Correct me if I wrong but isn't that looking to set the attributes in my bin file but the file is being saved directly a folder in my hard drive.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900