> (its actually a saved session that I *thought* was a fresh session..
That explains a lot.
> However, this data is still resource number 0 (which is the parameter I'm
> passing in to my Get call).. so why is it that the return value from Get
is
> 1 when I ask for 0..
My bad. I misremembered the format of the PreferencesDB. Each app preference
has the following elements:
- data (of some size)
- version (typically a small number)
- pref ID (typically a small number)
- creator ID (the app's creator ID)
Each of these "preference records" is stored as a resource in the
PreferencesDB resource database as follows:
- the version (two bytes) and data (arbitrary size) are concatenated to form
the contents of the resource
- the creator ID is used as the type of the resource
- the pref ID is used as the ID of the resource
So look at the first two bytes in the resource to find the version that the
pref was saved with.
If you see pref IDs up near 0xFFFF, they're the Exchange Manager's registry,
and not "real" app preferences.
--
Danny @ Palm
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/