--- Andy Yeong wrote:
> 
> ListPtr list;
> 
> *** To show ListBox ***
> list = GetObjectPtr(ListResourceIndex);
> list->attr.usable = 1;
> // And follow by the normal string init code
> LstDrawList(list)
> 
> *** To Clear up the ListBox ***
> list = GetObjectPtr(ListResourceIndex);
> list->attr.usable = 0;
> LstDrawList(list)

Why are you messing with the internal fields of a form object? 
(list->attr.usable = ...).  Don't do that.

You should use the provided API functions.  For example,

  // to show the list box
  FormPtr frmP = FrmGetActiveForm();
  FrmShowObject(frmP, FrmGetObjectIndex(frmP, ListResourceIndex));

  // to hide the list box
  FormPtr frmP = FrmGetActiveForm();
  FrmHideObject(frmP, FrmGetObjectIndex(frmP, ListResourceIndex));


__________________________________________________
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to