×

Discussion Board

Page 1 of 2 12 LastLast
Results 1 to 15 of 20
  1. #1
    Regular Contributor
    Join Date
    Aug 2005
    Posts
    78

    Next Line character in Nokia Phones

    Hi,

    I am testing my application on Nokia 6681 and Nokia 3250. I am using an Alert and I have printed a string that contains next line characters (\n) in the string, but when the application runs on the actual device, it doesn't display those \n characters. I mean, the string comes in continuation and those \n are just discarded.

    Is this a bug in Nokia implementation or there is something else to be done to acheive this.

    Regards,
    Ashish

  2. #2
    Regular Contributor
    Join Date
    Aug 2006
    Posts
    307

    Re: Next Line character in Nokia Phones

    Hi,

    Try \r\n instead of just \n characters

  3. #3
    Regular Contributor
    Join Date
    Aug 2005
    Posts
    78

    Re: Next Line character in Nokia Phones

    Hi axs,

    I have tried using \r\n and all possible ways to get the string to next line.

    Have you tried generating string on the next line.

    Regards,
    Ashish

  4. #4
    Super Contributor
    Join Date
    Dec 2005
    Location
    Europe/Poland/Warsaw
    Posts
    1,697

    Re: Next Line character in Nokia Phones

    hi Ashish,

    I can only confirm that with 6680 device and Alert item,
    if you can consider using Form screen instead of alert,

    regards,
    Peter

  5. #5
    Regular Contributor
    Join Date
    Aug 2005
    Posts
    78

    Re: Next Line character in Nokia Phones

    Hi Peter,

    My application is not device dependent. I am making one code and running on every device.

    You have suggested it for 6680. What about 3250? and N91? and many more new devices.

    Regards,
    Ashish

  6. #6
    Regular Contributor
    Join Date
    Aug 2006
    Posts
    307

    Re: Next Line character in Nokia Phones

    I think Peter's solution is a reasonable one. If you are thinking about the cross-platform solution, and you _really_ need to separate lines from each other, then Form would be a really nice option (especially if you are going to ask mobile user for confirmations, like during the acceptance for submitted names, surnames, addresses, etc.)

    Otherwise, I know that on oldy 7650 we had such bug, but solved it with doubled \n characters. I.e. try once more to use "\n\n" instead of "\n", maybe this is still the same bug
    Last edited by axs; 2006-08-23 at 13:02.

  7. #7
    Regular Contributor
    Join Date
    Sep 2005
    Posts
    138

    Re: Next Line character in Nokia Phones

    I've solved this issue using "\n \r\r" instead "\n\n"



  8. #8
    Super Contributor
    Join Date
    Dec 2005
    Location
    Europe/Poland/Warsaw
    Posts
    1,697

    Re: Next Line character in Nokia Phones

    hi,
    just btw:
    I've found that few times, MIPD2.0 docs links the same section in documentation about "line breaks" in docs:
    Line Breaks and Wrapping
    For all cases where text is wrapped, line breaks must occur at each newline character ('\n' = Unicode 'U+000A'). If space does not permit the full text to be displayed it is truncated at line breaks. If there are no suitable line breaks, it is recommended that implementations break text at word boundaries. If there are no word boundaries, it is recommended that implementations break text at character boundaries.
    http://java.sun.com/javame/reference...html#linebreak

    so I think we should expect using above to got linebreaks (newlines),
    regards,
    Peter

  9. #9
    Regular Contributor
    Join Date
    Aug 2005
    Posts
    78

    Re: Next Line character in Nokia Phones

    Hi,

    I have tried the solution of "\n \r\r" but it is not working on Nokia 3250.

    Pepper,
    What devices did you try this solution and can you please post you that piece of code on this thread.

    Peter,
    What I think of your post is that you are stressing on using Form instead of Alert to go for getting next line chars. But if I have to go that way, why in the world are Alerts provided in J2ME.

    Any positive responses.
    I think this is a bug in Nokia's implementation of J2ME.

    Regards,
    Ashish

  10. #10
    Regular Contributor
    Join Date
    Sep 2005
    Posts
    138

    Re: Next Line character in Nokia Phones

    I was using \n\n in a few mobiles, working well, but not in nokia 6280. I tried this solution in the 6280 and works!

  11. #11
    Regular Contributor
    Join Date
    Aug 2005
    Posts
    78

    Re: Next Line character in Nokia Phones

    Hi Pepper,

    That means you have not tried it on Nokia 3250, and also there is no common call for the same.

    It varies from handset to handset. Is it so???

    Regards,
    Ashish

  12. #12
    Super Contributor
    Join Date
    Dec 2005
    Location
    Europe/Poland/Warsaw
    Posts
    1,697

    Re: Next Line character in Nokia Phones

    Quote Originally Posted by ashishga
    Peter,
    What I think of your post is that you are stressing on using Form instead of Alert to go for getting next line chars.
    hi Ashish,
    no, rather I posted that because I wondered if that is supposed to be standard "newline" char ('U+000A') accross implementations - no matter what displayable is used to render string,

    regards,
    Peter

  13. #13
    Regular Contributor
    Join Date
    Aug 2005
    Posts
    78

    Re: Next Line character in Nokia Phones

    Hi Peter,

    But that is not the case, different displayables are treating new line characters in different ways, only on Nokia phones.

    I am sure, this is soem kind of issue in the Nokia's implementation and Nokia should look in to it.

    Regards,
    Ashish

  14. #14
    Regular Contributor
    Join Date
    May 2006
    Posts
    123

    Re: Next Line character in Nokia Phones

    hi..Friends..we do have next line charcater in Symbian..we find it in aknconstants.h header file..with..KNewLine..

  15. #15
    Registered User
    Join Date
    Oct 2006
    Location
    philippines
    Posts
    40

    Re: Next Line character in Nokia Phones

    Quote Originally Posted by sumanthgwn
    hi..Friends..we do have next line charcater in Symbian..we find it in aknconstants.h header file..with..KNewLine..
    can somebody give a simple way to use it?
    like:
    1) is this how to use it?
    "this is a string KNewline and another string"


    2) string1 = "this is a string"
    string 2 = "and another string"
    str = string1 + KNewline + string2

    which one?

    thanks
    misfit - a square peg in a round hole.

Similar Threads

  1. What is the real problem to receive data calls with Nokia TDMA cel modems?
    By jackal_jr in forum PC Suite API and PC Connectivity SDK
    Replies: 1
    Last Post: 2002-12-09, 09:02
  2. What is the real problem to receive data calls with Nokia TDMA cell modem?
    By jackal_jr in forum PC Suite API and PC Connectivity SDK
    Replies: 0
    Last Post: 2002-12-04, 16:05

Posting Permissions

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