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

Web and WebWorks Development

Reply
Developer
Developer
Posts: 137
Registered: ‎06-01-2009
My Device: Not Specified

Widget -- CSS and Height

I am building a widget for Storm 2 (OS 5.0) using Visual Studio 2008. I have CSS file.

 

A section in CSS as shown below to determine the height of the widget.

 

# main {

position: relative;

height: 470px;

}

 

However since Storm 2 supports both Portrait and Landscape, I should avoid hard coding the height. So I replaced the logic above to the one below: However it did not work and layout gets mixed up. Any idea what should be done to avoid hard coding the height.

 

# main {

position: absolute;

height: 90%;

}