Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Available space on NAS
Message
From
20/02/2014 22:53:35
 
 
To
20/02/2014 21:25:45
General information
Forum:
ASP.NET
Category:
Other
Environment versions
Environment:
VB 9.0
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Web
Miscellaneous
Thread ID:
01594835
Message ID:
01594854
Views:
45
>>If you just want to make sure your application isn't going to run out of free space, then you really only care about the volume(s) to which you have been granted access. If these are mounted on your local computer as SMB/CIFS volumes, then they should respond to DOS, Win32 or .Net calls to get information about them. Googling I find http://msdn.microsoft.com/en-us/library/system.io.driveinfo%28v=vs.110%29.aspx?cs-save-lang=1&cs-lang=vb#code-snippet-1 . The .TotalSize, .TotalFreeSpace and (especially) .AvailableFreeSpace properties should give you what you need.
>
>This is good if you have a map drive. Because, this requires a map letter. If you try to use \\NAS\ShareName, this will give:
>
>"Object must be a root directory ("C:\") or a drive letter ("C")."
>
>This is why I was not able to use that approach on the VM.

How about http://stackoverflow.com/questions/14465187/get-available-disk-free-space-for-a-given-path-on-windows ?
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform