Now whenever you need a scrollbar use FrmAddSpaceForObject() to copy the scrollbar from the form template into your own form.
You can resize and reposition the scrollbar using standard Frm... functions.
This technique is independent of ALLOW_ACCESS_TO_INTERNALS_OF_FORMS and should work in all OSs which have FrmAddSpaceForObject() [they all do, don't they].
FrmAddSpaceForObject is in the "System Use Only" function list in the Palm OS SDK reference. From looking at CoreTraps.h, it was added in OS 3.0.
While most of the parameters to this function can be computed using documented APIs, the final parameter, UInt16 objectSize, relies on information that can and will change between OS versions. You can't use "sizeof(ScrollBarType)", since that is private information and inaccurate when ALLOW_ACCESS_TO_INTERNALS_OF_SCROLLBARS isn't defined.
--
Ben Combee <[EMAIL PROTECTED]>
CodeWarrior for Palm OS technical lead
Palm OS programming help @ www.palmoswerks.com
-- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
