I have an application that should read various file.
When the user click on the "Next" button the display should show the contain of the next file....

So, I don't know how to auto-increment the name of the file..
In fact the file are called:
01.txt
02.txt
03.txt
etc...

This is the code:

in the header file:

=|=|=|=|=|=|=|=|=|=|=|=|=|=|

private:
RFile File;
RFs fsSession;
TBuf8 <16> Riga;

=|=|=|=|=|=|=|=|=|=|=|=|=|=|

in the CPP file:

=|=|=|=|=|=|=|=|=|=|=|=|=|=|

void MyApplication::Open()
{
_LIT(Archivio, "c:\\lavori\\01.txt");
fsSession.Connect();
File.Open(fsSession,Archivio,EFileShareExclusive|EFileRead);
File.Read(Riga);
File.Close();
fsSession.Close();
}

=|=|=|=|=|=|=|=|=|=|=|=|=|=|

This code works fine, it open ONLY the file 01.txt and read the text...

But I want something that when I call Open Function the first time it open the 01.txt, the second time it open the 02.txt, etc..
Something that autoincrement the name of the file...

Is it possible ?? If yes how ??? Let me know !!!

Stefano - pergine@freemail.it