fgetc() moves pointer one step forward I have opened a file using handle = fopen("rw.txt"). 
The file consist of 3 values which is separated with spaces 
ex: 12 23 34 
using isspace(fgetc(handle)) 
Problem here is that fgetc() increments the internal pointer,  making store incorrect strings including string. 

Can these three values be stored in some different way, making me store these values, and ignore the whitespace using NXC syntax?

Here is my current code:

#import "value.txt" val
task main()
{   
    byte handle;
    handle = fopen("value.txt", "r");
    if (handle != NULL)
        {
            string a;
            string b;
            string c;
            int count = 0;

           while(count &lt;= 2)
           {    
               if(!isspace(fgetc(handle)))
               {    
                   if(count == 0)
                   {
                         fgets(a, 2, handle);
                         TextOut(0, LCD_LINE3, "done a" + a);   
                         TextOut(0,LCD_LINE4," lenght: " + NumToStr(strlen(a)));
                         Wait(3000);    
                         count = count + 1;
                         ClearScreen();             
                   }
                   else if(count == 1)
                   {
                        fgets(b, 2, handle);
                        TextOut(0, LCD_LINE3, "done b" + b);
                        Wait(3000); 
                        count = count + 1;
                        ClearScreen();          
                   }
                   else if(count == 2)
                   {
                        fgets(c, 2, handle);
                        TextOut(0, LCD_LINE3, "done c" + c);
                        Wait(3000);
                        count = count + 1;
                        ClearScreen();
                   }   
               }

                TextOut(0, LCD_LINE3, "done" + NumToStr(count));
               Wait(3000);
               ClearScreen();

            }

        }
    }

}
The most basic solution would be to store the character read by fgetc, for example, instead of:

if(!isspace(fgetc(handle)))


you'd write:

char val = fgetc(handle);
if(!isspace(val))


This way if the isspacecall returns false you will still have the latest character in the val variable.

I'd also suggest you look into the switch statement instead of using multiple if-else blocks: http://bricxcc.sourceforge.net/nbc/nxcdoc/nxcapi/switch.html