Main Menu

HOME

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

US Job listings




   Misc

   Amazon

   Links

    


Disk diagnostics
 

 

Description

This example uses the biosdisk() function which provides bios disk services , in this case we are running the disk diagnostics command .

Code

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

int main(void)
{

int status;
int command = 19;
int drive = 0;
int head = 0;
int track = 1;
int sector = 1;
int nosectors = 1;
char buffer[512];

clrscr();
status =
biosdisk(command,drive,head,track,sector,nosectors,buffer);
if(status == 0)
printf("Diagnostics.\n");
else
printf("Unable to run diagnostics.\n");
return 0;

}

Information

 

 

 

 

 

 

 




   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
display all processes on your system(VB)
Add lines of text to a file(VB)
Valid link(PHP)
typewriter status bar(Javascript)
delete files on a floppy disk(VB)
total amount of function keys(VB)
using the md5 function to encrypt data(php)
check if a file exists(C Sharp)

    




Copyright © 2003 by programmershelp.co.uk