일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 | 26 | 27 | 28 | 29 | 30 | 31 |
Tags
- windows
- Coding
- commit
- git
- string
- log
- csharp
- nullable
- C#
- algorithm
- windows10
- convert
- .net
- tls
- dotNET
- Github
- ListView
- logging
- IValueConverter
- coding-test
- File
- programmers
- Binding
- mysql
- Process
- WPF
- 코딩테스트
- Microsoft
- Visual Studio
- chashtag
Archives
- Today
- Total
목록filelock (1)
CHashtag

public bool CheckFileLocked(string filePath) { try { FileInfo file = new FileInfo(filePath); using (FileStream stream = file.Open(FileMode.Open, FileAccess.Read, FileShare.None)) { stream.Close(); } } catch (IOException) { return true; } return false; } 감사합니다.
C#
2021. 2. 8. 15:17