Main Menu

HOME

.Net
ASP
Assembly
C
C++
Delphi
HTML
Java
JavaScript Site
MySQL
PC interface
Powershell
Perl
PHP
VBScript
Visual Basic
XML

US Job listings




   Misc

   Amazon

   Links

    


Free disk space in DOS
 

 

Description

Reports the free disk space on a DOS system.

Code

#include <stdio.h>
#include <dos.h>

void main(void)
{
struct dfree diskinfo;
long disk_space;

getdfree(3, &diskinfo);
disk_space = (long) diskinfo.df_avail * (long) diskinfo.df_bsec * (long) diskinfo.df_sclus;

printf("Available disk space %ld\n", disk_space);
}

Information

tested using Turbo C on a DOS system

 

 
 

 

Download

diskfreedos.txt


 




   Sponsors
 

   Software
500 Java Tips E-book
PHP editor
PERL editor
Beginning Java
Beginning Visual Basic
Learn VB.net
Learn VB 6
VB and databases
ASP image library
C++ builder programming
C++ fundamentals

   Source Code
perform a DNS query(C Sharp)
extract a zip file to a folder(PHP)
underline text in a string(php)
fire routine(Assembly)
change system colors(VB)
Random number(ASP.net)
mysql version(php)
insert contents of text file into a text box(VB)

    




Copyright © 2003 by programmershelp.co.uk