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

Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.

New Contributor
Posts: 2
Registered: ‎06-17-2012
My Device: 9550
My Carrier: Airtel

Background image causes scrolling

Hi All,


I have added a background image to VerticalFieldManager . 


VerticalFieldManager verticalFieldManager = new VerticalFieldManager(

| VerticalFieldManager.USE_ALL_HEIGHT) {


// Override the paint method to draw the background image.
public void paint(Graphics graphics) {
// Draw the background image and then call paint.
graphics.drawBitmap(0, 0, getWidth(), getHeight(), image, 0, 0);



Now when I add this manager to my screen then it causes the scroll arrows to come on right top and bottom of screen although the image perfectly fits the dislayable area. When I scroll down it simply scrolls down indefinately and shows a white screen (the background image which I using has Blue color).


If I remove VerticalFieldManager.USE_ALL_HEIGHT , then the image does not show unless I add some componenets in this field manager.


Not sure whats going on.


Thanks !

Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: Background image causes scrolling

I think you need to add NO_VERTICAL_SCROLL.


But I think this is all expained in this KB article, which I suggest you review. 


New Contributor
Posts: 2
Registered: ‎06-17-2012
My Device: 9550
My Carrier: Airtel

Re: Background image causes scrolling

Thanks it worked but now when the keyboard is up I cannot see fields which are below the keyboard.


How do I overcome this ?


Thanks and Regards.

Posts: 2,268
Registered: ‎07-08-2009
My Device: various
My Carrier: various

Re: Background image causes scrolling

I suggest you try creating MainScreen with NO_VERTICAL_SCROLL and your VerticalFieldManager displaying the background with USE_ALL_HEIGHT and VERTICAL_SCROLL. See if that helps.


In fact, that is pretty much what was suggested in the article Peter quoted, though I never fully spelled it out there. I don't guarantee it will work as you want it to - the way virtual keyboard works is a puzzle at times Smiley Happy


Good luck!

please click 'Accept Solution' on posts that provide the solution to the question you've posted. Don't say "Thanks", press 'Like' button instead!