Todd Cary <[EMAIL PROTECTED]> wrote:
> I am learning the Palm OS via Pocket Studio, the Pascal version of the
> Palm development environment. So, far everything is working well. I
> have a Wine list DB with the appropriate editing form. However, I now
> want to add the features that make the Palm such a great PDA: drop-downs
> for the fields. If I can get some guidance in C/C++ on where/how to add
> a drop-down to one of the fields (e.g. Variety), I am sure I will be
> able to move on and apply them to others.
>
> Do I need to replace the Field "Variety" with a drop-down on the Edit
> Form?
>
> Do I need to create another DB for the Varieties?
How many varieties will you have? If you'll have 16 or less, you can use
the built in category features for your varieties, and the store each record
with one of these categories (i.e. the variety). This will make filtering
your list of wines by variety pretty easy. You can provide a set of
varieties at build time and then edit them at runtime as needed. You'll use
a trigger and a list to implement the drop down, but there are special
category functions that make this different than other lists.
If you have more than 16, or have other attributes of each wine that you
want to track, then you probably want to add "fields" to each "record" for
this information. In this case, you could store the varieties in a
different database, in your preferences, or in a fixed record in your
database. You'll use a trigger and a list to implement the drop down.
Since you're able to translate from C solutions to Pascal solutions, if you
haven't done so already, check out one of the many Palm programming books.
Databases aren't hard once you think about them the right way. A good
introductory book can help you learn to think about them the right way.
HTH
Jeff
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/