BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 10-27-2008, 05:42 AM   #1 (permalink)
New Member
 
Join Date: Jul 2008
Model: Curve
PIN: N/A
Carrier: ts
Posts: 5
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default Multi lines LabelField?

Please Login to Remove!

Hi Experts,
Is there anyway to show message with multi lines in LabelField?
This doesnt work as expected

String text = lable.getText();
text += ('\r\n' + "newText");
lable.setText(text);

it only get wraps when its fill the top line :(

Thanks in advance.
Dishan
Offline  
Old 10-27-2008, 09:14 AM   #2 (permalink)
Thumbs Must Hurt
 
Join Date: Apr 2008
Model: 8130
PIN: N/A
Carrier: US Cellular
Posts: 82
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Why are you enclosing \r\n in single quotes? That is used to enclose a single character. Try using double quotes, because I believe the second character, \n, which is the important one, is being ignored.
Offline  
Old 10-30-2008, 12:03 AM   #3 (permalink)
New Member
 
Join Date: Jul 2008
Model: Curve
PIN: N/A
Carrier: ts
Posts: 5
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

hmmm It doent work. :(
Its a chat screen. So I want to append user entered text into Lable with newLine
Offline  
Old 10-30-2008, 03:53 AM   #4 (permalink)
CrackBerry Addict
 
Join Date: Apr 2005
Location: hamburg, germany
Model: 8900
Carrier: o2
Posts: 838
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

assuming newtext is a String with some new text and lable is your LabelField:
Code:
lable.setText(lable.getText()+"\n"+newtext);
__________________
java developer, Devinto, hamburg/germany
Offline  
Old 10-30-2008, 10:10 AM   #5 (permalink)
New Member
 
Join Date: Jul 2008
Model: Curve
PIN: N/A
Carrier: ts
Posts: 5
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

I used LabelField and Its only works after first line fill up. Is there any reason for this.?
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

PLE 40Mhz Crystal Oscillator 40.000000 Mhz Half Can NEW Amiga Apple PC
$2.75
PLE 40Mhz Crystal Oscillator 40.000000 Mhz Half Can NEW Amiga Apple PC pictureNEW Motorola MC68030RC40B 40Mhz PGA 128 Pin Gold Amiga Apple CPU MMU Processor
$28.95
NEW Motorola MC68030RC40B 40Mhz PGA 128 Pin Gold Amiga Apple CPU MMU Processor pictureCommodore Amiga Time Base Corrector VT-2000 TBC II Digital Processing (D9-5)
$250.0
Commodore Amiga Time Base Corrector VT-2000 TBC II Digital Processing  (D9-5) pictureCommodore Amiga Power Supply PA-4201-5A A2000 A2500 A3000 A4000 (D4)
$65.0
Commodore Amiga Power Supply PA-4201-5A     A2000 A2500 A3000 A4000       (D4) pictureCommodore Amiga Supraram 2000 4mb Expansion A2000 A2500 A3000 A4000 (D9-3)
$45.0
Commodore Amiga Supraram 2000 4mb Expansion A2000 A2500 A3000 A4000    (D9-3) picture






Copyright 2004-2016 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.