BlackBerry Forums Support Community
              

Closed Thread
 
LinkBack Thread Tools
Old 04-21-2009, 04:05 PM   #1 (permalink)
Knows Where the Search Button Is
 
Join Date: Apr 2009
Model: 7100t
PIN: N/A
Carrier: verizon
Posts: 21
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default RichTextField causing an illegalstateException

Please Login to Remove!

Hello,

I have a VerticalFieldManager containaing multiple HorizontalFieldManager containing a RichTextField, a BasicEditField and a SeparatorField.

Before pushing the mainscreen of my application, I create all these objects and add the verticalFieldManager to the mainscreen.

If I build the RichTextFields like this
Code:
RichTextField label = new RichTextField(listName, RichTextField.NON_FOCUSABLE  | RichTextField.USE_TEXT_WIDTH) {
            protected void paint(Graphics graphics) {
                graphics.setBackgroundColor(leftColor);
                graphics.clear();
                super.paint(graphics);
            }
        };
it works well.

But if I do it like this:
Code:
RichTextField label = new RichTextField(listName, RichTextField.NON_FOCUSABLE) {
            protected void paint(Graphics graphics) {
                graphics.setBackgroundColor(leftColor);
                graphics.clear();
                super.paint(graphics);
            }
        };
I get an illegalstateexception when pusing the screen.

Any idea why? How can I change the USE_TEXT_WIDTH?

thanks
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

Fujitsu Teampos 7000F POS 7NF34020004E00C i3-2120 @3.3GHZ 4GB RAM
$229.68
Fujitsu Teampos 7000F POS 7NF34020004E00C i3-2120 @3.3GHZ 4GB RAM pictureJCB 3CX 3D AND 3DX DIPPER RAM SEAL KIT -PART NUMBER 550/42098
$45.0
JCB 3CX 3D AND 3DX DIPPER RAM SEAL KIT -PART NUMBER 550/42098 pictureINTEL E139761 PENTIUM II MOTHERBOARD W/RAM+VGA+LAN+CPU
$49.99
INTEL E139761 PENTIUM II MOTHERBOARD W/RAM+VGA+LAN+CPU pictureSirona Cerec AC LQ SW Cerec 4.4 Premium/ inLab 4.2 24 GB RAM
$5500.0
Sirona Cerec AC LQ SW Cerec 4.4 Premium/ inLab 4.2 24 GB RAM pictureCASE EXCAVATOR CX800 A B SERIES CYLINDER DIPPER SEAL RAM KIT
$386.15
CASE EXCAVATOR  CX800 A B SERIES CYLINDER DIPPER SEAL RAM KIT  picture






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