john pfeiffer
  • Home
  • Categories
  • Tags
  • Archives

win ce from file mouse get file line

/*  */
getFileLine( FILE* fp, char buffer[128], int buffermax )
{   int i=0;
    char c;
    if( fp==NULL )
    {   printf("\nfopen error\n");
        exit(1);
    }else{  
        do{
        c=fgetc(fp);
        buffer[i]=c; 
        i=i+1;
        printf("%c",c);

        }while( 
c!= '\n' && c!=EOF && (i< buffermax )    );
        }
/* replace the newline with a string terminator */
if( i>1 && buffer[i-1] == '\n' )
{   buffer[i-1] = '\0';     }
}/* end function  */

  • « Win CE from file mouse main
  • Win CE from file update window main »

Published

Feb 24, 2010

Category

c

~40 words

Tags

  • file 92
  • get 22
  • line 31
  • mouse 5
  • win-ce 40
  • win-fromfile-mouse 4