I'm not sure if this is what you're after, it's not 'dynamically creating a 
scrollbar', but it's how you can fake it...

In my app I need to display a bunch of text. I show the scrollbar if that text 
goes over the number of lines I'm able to display on the screen, otherwise I 
don't show the scrollbar. I do this by adding the scrollbar in the Resource 
Editor. If the number of lines of text is less than or equal to the number of 
lines I can display, I increase the width of my text field by 7 (which is the 
width of the scrollbar) and the scrollbar is not displayed (check the docs for 
the SclSetScrollBar fn for why). If the number of lines of text is greater than 
the number that can be displayed at one time, I don't expand the width of the 
text field and the scroll bar is displayed.
-- 
For information on using the PalmSource Developer Forums, or to unsubscribe, 
please see http://www.palmos.com/dev/support/forums/

Reply via email to