ASP ScriptingJava ScriptingCGI ScriptingHTMLJavaLanguage CERP Education Links

LANGUAGE C

Saving & Restoring Screen

     By using the Turbo C library functions -gettext() and -puttext(), the prototypes of both are defined in the header file conio.h. gettext() is used to get the contents of the screen area and puttext() is used to restore the same. 

#include <stdio.h>
#include <conio.h>
main ( )
{
char text[4000];
int x, y;
for ( y=1; y <=25; y++)
{
for ( x=1; x <=80; x++)
{
gotoxy( x, y );
printf ( " Very Good   ! " );
}
}
gettext ( 1, 2, 80, 25, text)
{
getch();
clrscr();
printf ( " Press a key to restore screen...." );
getch();
puttext( 1, 1, 80, 25, text);
}

 


Your Ad Here
Not All Of Your Subscribers Use RSS - AWeber Email Marketing
Your Ad Here