Comments (6)
Comment by Yomodo from Friday Jan 09, 2015 at 11:35 GMT
What type of device is G: (external drive, USB stick, ...)
NTFS formatting?
from alphafs.
Comment by hnorihiro from Wednesday Jan 14, 2015 at 01:03 GMT
Yes, it is NTFS(USB Drive).
Drive When it is empty after formatting, occurs error.
Drive When $RECYCLE.BIN exist,does not occurs.
from alphafs.
Comment by Yomodo from Wednesday Jan 14, 2015 at 23:24 GMT
Does it still throw the exception if you execute: info.Refresh();
first?
from alphafs.
Comment by hnorihiro from Thursday Jan 15, 2015 at 01:49 GMT
OS Windows7
.NET 3.5
DirectoryInfo info = new DirectoryInfo(@"G:\");
info.Refresh();
info.GetFileSystemInfos();//Directory not found Exception
it still throw the exception .
from alphafs.
Comment by Yomodo from Thursday Jan 15, 2015 at 10:14 GMT
Confirmed on Windows 8.1 X64
It seems related to the volume label.
The exception can be avoided with: /v:myLabel
But even then I still see the Exception thrown, sometimes.
var drive = @"D:";
var format_cmd = "/C format.com " + drive + " /fs:NTFS /v:myLabel /q";
using (var process = Process.Start("CMD.exe", format_cmd))
process.WaitForExit();
DirectoryInfo info = new DirectoryInfo(drive + @"\");
info.GetFileSystemInfos();
However, System.IO indeed does not throw an Exception.
from alphafs.
Unfortunately, I could not find anything to fix within AlphaFS.
The only possbile fix for this issue,
is to add a: Thread.Sleep(1000);
before calling DirectoryInfo()
.
from alphafs.
Related Issues (20)
- ExistsDrive tweak?
- CreateJunction doesn't work when the junction target is a volume-prefixed path
- Root directory enumeration is broken on develop
- Cannot pipe commands in Powershell HOT 2
- File.Copy using \\?\Volume{guid} syntax throws not ready error HOT 2
- Cancel a current copy-process? HOT 2
- .NET 5.0 support HOT 9
- EnumerateAlternateFileStreams includes default data stream
- PathTooLongException thrown on paths less than 32,000 chars. HOT 1
- BackupWrite Native method return (13) the data is invalid
- (FileInfo|DirectoryInfo).Copy() mutates the instance's path
- System.IO.IOException: (6801) Transaction support within the specified resource manager is not started or was shut down due to an error
- Is AlphaFS dead? HOT 3
- Request help reproducing behaviour
- Alphaleonis.Win32.Filesystem.DeviceNotReadyException bug HOT 1
- This isn't an issue with you, but a relation to another git. I come seeking discussion. HOT 2
- DFS implementation examples missing.
- How to install AlphaFS? HOT 1
- The device is not ready error
- [Question] Has this project been resurrected??
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from alphafs.