Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Developer
Posts: 146
Registered: ‎11-05-2008
My Device: Not Specified

problem on FlowHorizontalManager

Hi,

Why every field has added to flowhorizontal manager in a new row,when there is enough spave to occupy another field.Please help.It's very urgent.

Developer
Posts: 146
Registered: ‎11-05-2008
My Device: Not Specified

Re: problem on FlowFieldManager

Sorry .It will be Flowfieldmanager.
Developer
Posts: 19,631
Registered: ‎07-14-2008
My Device: Not Specified

Re: problem on FlowHorizontalManager

Most Fields will, by default, use the full width of the Display when setting their width.  So FlowFieldManager thinks it can only fit one Field per row.  To change this behavior, you need set the width used by each Field.  This is covered in the following KB article:

 

How To - Create custom fields
Article Number: DB-00120

http://www.blackberry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800505/800345/...

 

So you need to override the layout method and call setExtent with the correct width for your Field.  Then FlowFieldManager will attempt to fit as many fields in a row as it can.

Developer
Posts: 146
Registered: ‎11-05-2008
My Device: Not Specified

Re: problem on FlowFieldManager

Many Thanx for reply.I m doing with ur suggestion.One question,suppose I have added a long text to a normal field(say editfield),the text is greater than screen width,so next string will be come to next row.here the width of field will be screen width or the sum of the width of whole texts?

Thanx

BlackBerry Development Advisor
Posts: 15,211
Registered: ‎07-09-2008
My Device: BlackBerry Passport
My Carrier: Bell

Re: problem on FlowFieldManager

I think this sample will help you with what you are trying to accomplish.

 

Pimp My Object: Creating a TextBox Field

http://na.blackberry.com/eng/devjournals/resources/journals/jul_2005/creating_textbox_field.jsp

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker