Ben,

Thanks very much for that API. I originally thought it was for opening something other than the system preferences. But I'm using it now.

Lorraine

At 02:54 PM 10/26/2004 -0500, you wrote:
At 02:10 PM 10/26/2004, you wrote:

Help!
Does anyone know how to open up whatever file or database the system preferences are stored?
I've searched all over the Preferences API documentation and Preferences.h header file but it doesn't show you how to access the entire database/file/whatever, only how to get/set one preference at a time. I've tried using...
DmGetNextDatabaseByTypeCreator(true, &stateInfo, 'sprf', sysFileCPreferences, true, &cardNo, &dbId); For the 3rd arg, I've tried using 'sprf', 'pref' and even 'data'. They all failed to find anything. I've read about the collection of DmFindResource APIs but they all assume you already have the database and know the resource id and type you're looking for. And I don't even know if these preferences are considered a resource.

In addition to Matthew's helpful post (very similar to what I was about to write), there's also a nice system API called PrefOpenPreferenceDB that lets you directly open either than saved or unsaved preference database. Note that this API will cause a warning on debug versions of Palm OS Cobalt, even from 68K code, so it's better to just open the prefs DB directly.


-- Ben Combee, Technical Lead, Developer Services, PalmSource, Inc.
   "Combee on Palm OS" weblog: http://palmos.combee.net/
   Developer Fourm Archives:   http://news.palmos.com/read/all_forums/



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


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

Reply via email to