Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > C# and C > C++ and Visual C++ > C++ Programming
Password Reminder
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
C++ Programming General discussions for the C++ language. For questions specific to Microsoft's Visual C++ variant, see the Visual C++ forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the C++ Programming section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old May 20th, 2004, 01:37 AM
Registered User
Join Date: May 2004
Location: Blumenau, Santa Catarina, Brazil.
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to liesberg
Default How to get free disk space in win32

Hi there

  I want to know how to get the free disk space for a drive (e.g.:C:\) in win32 with c++. What is the API function and how to use it ?

Thanks very much
liesberg (liesberg@bol.com.br)

Reply With Quote
  #2 (permalink)  
Old July 3rd, 2004, 10:48 AM
Authorized User
Join Date: Dec 2003
Location: Bristol, , United Kingdom.
Posts: 25
Thanks: 0
Thanked 0 Times in 0 Posts

struct dfree dtable;
   getdfree(1, &dtable);
   discspace = (long) dtable.df_avail * (long)dtable.df_bsec * (long)dtable.df_sclus;

Reply With Quote
  #3 (permalink)  
Old July 13th, 2007, 03:17 PM
Registered User
Join Date: Jul 2007
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts

The instructions given don't work in C Borland compiler, even with all the necessary #include(s).

I am still looking for an answer to Liesberg question.
Claudio (pinheiro.claudio@uol.com.br)
Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Monitor disk space gregalb SQL Server 2000 3 July 11th, 2007 05:36 PM
Need a Script to Monitor Free Disk Space remotely Vishal Saini Windows Server 0 June 22nd, 2007 09:31 AM
Wiping Free Space Michael109 Intro Programming 3 June 20th, 2007 02:10 AM
how to check free space on disk using FTP client? woojtii C# 2005 1 June 5th, 2007 02:13 AM
Free space on disc elansolutionsltd Access VBA 3 February 26th, 2006 08:17 AM

All times are GMT -4. The time now is 05:36 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.