Ok i created this little dumb prog.. that will output text from a text file.. but.. there is one thing.. the text goes all accross the screen
and i want it so that on a certain char it will just go to the next like i tried it.. but i keeped getting errors =(
Code:
#include <stdio.h>
#include <stdlib.h>
int main( )
{
char Filename[10] = "test.txt";
char buff[356];
int lenght;
FILE *fp;
if(( fp = fopen( Filename, "r" )) == NULL )
{
fprintf( stderr, "Could not open %s for reading", Filename );
exit( 1 );
}
fgets( buff, 356, fp );
fprintf( stdout, " %s ", buff );
getchar( );
return 0;
}