×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Regular Contributor
    Join Date
    Nov 2006
    Posts
    59

    Unique problem regarding incorrect output from Buffer

    Hi friends,
    I am facing an unique problem when i am trying to give bufferd output with the help of CAknInformationNote.

    when i use

    TBuf16<128> bLocation;
    bLocation.AppendFormat(_L("Area : %S\n"),&namePtr);
    CAknInformationNote* informationNote1 = new ( ELeave ) CAknInformationNote;
    informationNote1->ExecuteLD( bLocation )

    it gives correct output means character output.

    but when i use


    TBuf<255> bLogData
    bLogData.Format(_L("Area: %d\nREGION: %d\nSTATE: %d\nCOUNTRY: %d\nNETWORK: %S\n"),&namePtr,aLocation,aMnc,aMcc,&iLongNwName);
    it
    CAknInformationNote* informationNote = new ( ELeave ) CAknInformationNote;
    informationNote->ExecuteLD( bLogData );

    It is giving me wrong output means it is giving me numerical output.

    could any one help me in getting the correct output.

  2. #2
    Super Contributor
    Join Date
    Jun 2006
    Location
    Moscow, Russia
    Posts
    803

    Re: Unique problem regarding incorrect output from Buffer

    Hi,

    I think it works as it should. You are using %d instead of %S when formatting the string in the sample code fragment.
    Check the following article in the SDK help:
    Symbian OS v9.1 » Symbian OS guide » Base » Using User Library (E32) » Buffers and Strings » Using Descriptors » How to Use Descriptors » Format string syntax
    Regards,
    ivey

  3. #3
    Nokia Developer Champion
    Join Date
    Mar 2006
    Location
    Helsinki, Finland
    Posts
    8,345

    Re: Unique problem regarding incorrect output from Buffer

    Hi,
    Quote Originally Posted by abhijeetguptag

    TBuf16<128> bLocation;
    bLocation.AppendFormat(_L("Area : %S\n"),&namePtr);
    CAknInformationNote* informationNote1 = new ( ELeave ) CAknInformationNote;
    informationNote1->ExecuteLD( bLocation )
    it gives correct output means character output.

    but when i use


    bLogData.Format(_L("Area: %d\nREGION: %d\nSTATE: %d\nCOUNTRY: %d\nNETWORK: %S\n"),&namePtr,aLocation,aMnc,aMcc,&iLongNwName);

    It is giving me wrong output means it is giving me numerical output.

    could any one help me in getting the correct output.
    Can't you see something wrong there???

    PS: Don't forget to read what Ivey has suggested.

    Kiran.

  4. #4
    Regular Contributor
    Join Date
    Nov 2006
    Posts
    59

    Re: Unique problem regarding incorrect output from Buffer

    Quote Originally Posted by kiran10182
    Hi,


    Can't you see something wrong there???

    PS: Don't forget to read what Ivey has suggested.

    Kiran.
    Thanks Kiran and Ivey,

    I just forgot to do this basic.
    Thanks

Similar Threads

  1. Replies: 4
    Last Post: 2007-09-10, 10:18
  2. Replies: 6
    Last Post: 2005-10-03, 05:51
  3. input output SocketConnection problem
    By emil69asec in forum Mobile Java Networking & Messaging & Security
    Replies: 3
    Last Post: 2004-07-09, 07:25
  4. Replies: 0
    Last Post: 2004-06-13, 12:53
  5. MirrorProtocolParser.invokeMethod(Method, Object[]): Failure! Problem Pl Help me out
    By montooshah in forum Mobile Java Media (Graphics & Sounds)
    Replies: 1
    Last Post: 2003-10-20, 15:17

Posting Permissions

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