将Wav文件另存为只读 [英] Save Wav file as read only

查看:102
本文介绍了将Wav文件另存为只读的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在保存一个wav文件,但无法弄清楚如何保存它,因此属性是只读的.

I am saving a wav file but cannot figure out how to save it so the attributes are read only.

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)

推荐答案

System.IO.File.SetAttributes(Filetosave, IO.FileAttributes.ReadOnly)


可以'不能让它起作用.如果我错了,请纠正我,但不是要在我的bin文件中设置属性,而是将文件直接保存在硬盘中的文件夹中.
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.


这篇关于将Wav文件另存为只读的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆