Discussion Board

Results 1 to 2 of 2
  1. #1
    Regular Contributor
    Join Date
    Aug 2004

    Read file with TFileText


    I would like to read a file with TFileText. It works for the first line but after, it reads nothing.

      RFile filesave;
      filesave.Open(fsSession, nameFile, EFileRead);
      TFileText ft;
      //Read the first line
      HBufC* Detail = HBufC::NewL(3);
      TInt ty = ft.Read(Detail->Des());
      //Transform the number
      TLex conv( Detail->Des() );
      conv.Val(nb); //The number is OK
      //Read the second line
      HBufC* Detail2 = HBufC::NewL(3);
      TInt ya = ft.Read(Detail2->Des());
      //Transform the number
      TLex convTemp( Detail2->Des() );
      convTemp.Val(nb2); //nb2 is 0 !!!!
    I don't understant why the TFileText doesn't return the write number.

    Please help me.

    Thank you,


  2. #2
    Super Contributor
    Join Date
    Nov 2005

    Re: Read file with TFileText

    I've just raised a question about this to your posting on NewLC, to get more information about the problem (http://forum.newlc.com/index.php/topic,12865.0.html)

    Perhaps you could post the same information here...Thanks.

Similar Threads

  1. read file line by line
    By maciejprzybycien in forum Symbian
    Replies: 10
    Last Post: 2008-04-10, 14:14
  2. read integer values out of a text file
    By michael.schrenk in forum Symbian
    Replies: 4
    Last Post: 2005-02-19, 19:55
  3. read text file
    By ivan6502 in forum Mobile Java General
    Replies: 1
    Last Post: 2005-01-17, 21:10
  4. Help me read a text file
    By margaretpoor in forum Symbian
    Replies: 1
    Last Post: 2004-05-24, 04:08
  5. File Handling... Read files from /res
    By Ralpharama in forum Mobile Java General
    Replies: 2
    Last Post: 2003-10-02, 17:30

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts