[ C# ]
file 사용여부
체크
try
{
using (Stream stream =
new FileStream("MyFilename.txt",
FileMode.Open))
{
// File/Stream manipulating code here
}
} catch {
//check here why it failed and ask user to retry if the file is in use.
}
댓글 없음:
댓글 쓰기