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
Developer
Posts: 34
Registered: ‎11-02-2009
My Device: Not Specified

How to draw BasicEditField border?

How can i draw border for BasicEditField in 4.2 like border of dialog in following image?

 

 

plz give me some code or sample if it is possible.

 

Thanks!

 

 

 

 

Developer
Posts: 3,951
Registered: ‎07-15-2008
My Device: Not Specified

Re: How to draw BasicEditField border?

Check this Thread.

 

http://supportforums.blackberry.com/t5/Java-Development/EditField-with-border/m-p/92811


Use Search. "Accept Solution" If the problem is resolved.
Highlighted
Developer
Developer
Posts: 34
Registered: ‎11-02-2009
My Device: Not Specified

Re: How to draw BasicEditField border?

Many thanks, i'll check it out. Hope it works

Developer
Posts: 265
Registered: ‎08-27-2009
My Device: Not Specified

Re: How to draw BasicEditField border?

Hi, I can provide you some thing for AutoEditField....i.e drawing the BackGround for autoeditField instead pf BasicEditField.

Developer
Posts: 265
Registered: ‎08-27-2009
My Device: Not Specified

Re: How to draw BasicEditField border?

Hi You can see the following snippet for Boundry arround a AutoEditFiled....

 

 

import net.rim.device.api.ui.component.*;
import net.rim.device.api.ui.*;

/**
 * 
 */
public class EditBoxCustom extends AutoTextEditField 
{
    public EditBoxCustom() 
    {    
    
    
    }
    
    public EditBoxCustom(String text,long Style)
    {
       super("","",800,Style);
    }
    
    public EditBoxCustom(String text,String intText,int index,long Style)
    {
       super("",intText,800,Style);
    }  
    
    
    protected void paintBackground(Graphics g) 
    {
        g.setColor(Color.BLUE);          
    } 
}