Discussion Board

Results 1 to 5 of 5
  1. #1
    Regular Contributor chintandhruva's Avatar
    Join Date
    Apr 2008
    Posts
    95
    Hi

    I am Newbie to symbian

    I want to add "\n" to TBuf

    I have written the following code for it

    TBuf<50> finalBuffer;
    finalBuffer.Append(number);
    finalBuffer.Append(_L("\n"));
    finalBuffer.Append(_L("Message:"));
    finalBuffer.Append(message);

    But No success any clue??

  2. #2
    Nokia Developer Moderator wizard_hu_'s Avatar
    Join Date
    Feb 2006
    Location
    Mallorca, Holiday
    Posts
    27,683
    Your new line character is there, do not worry. However it matters what you do with finalBuffer afterwards. CGraphicsContext:rawText will draw you a box for example. Various editors will treat it as a space (they use Unicode break characters, some of them are named at the end of CEditableText, like CEditableText::ELineBreak).

  3. #3
    Regular Contributor chintandhruva's Avatar
    Join Date
    Apr 2008
    Posts
    95
    Hi ...

    Thanks for the reply I am inserting the finalbuffer text in the CEikEdwin control using SetText Api but I am not able to see the effect of \n...

  4. #4
    Nokia Developer Moderator wizard_hu_'s Avatar
    Join Date
    Feb 2006
    Location
    Mallorca, Holiday
    Posts
    27,683
    For CEikEdwin, the remark about special characters apply.
    Use finalBuffer.Append(CEditableText::ELineBreak).

  5. #5
    Regular Contributor chintandhruva's Avatar
    Join Date
    Apr 2008
    Posts
    95
    Thank you for your reply....

    I added \f instead of \n and problem got solved....

Similar Threads

  1. help needed for using TBuf
    By jcrajan00 in forum Symbian C++
    Replies: 8
    Last Post: 2010-03-24, 07:30
  2. what will be the possible reasons for blocked call function..
    By amol_benare604 in forum Symbian C++
    Replies: 17
    Last Post: 2009-08-06, 15:16
  3. Dll中添加资源的问题,CONE14
    By seloda in forum Symbian
    Replies: 1
    Last Post: 2008-12-08, 06:25
  4. preverify error. PLZ HELP
    By michaelhann89 in forum Mobile Java Tools & SDKs
    Replies: 14
    Last Post: 2007-03-22, 22:51
  5. Tbuf Usage: Inside Headerfile Class
    By Alicia_S60 in forum Symbian C++
    Replies: 2
    Last Post: 2004-12-01, 04:19

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved