Patrick Porlan wrote in message <[EMAIL PROTECTED]>...
>
>> I am trying to use the PrefGetAppPreferences() call for the first
>> time, and according to the documentation, it is supposed to
>> return the number of bytes retrieved from the preferences
>> database.  However, it appears to be returning the version I give
>> to PrefSetAppPreferences() instead.  Does anyone know what
>> the correct behavior of these two functions is supposed to
>> be?  The Palm OS Reference appears to be incorrect in this case.
>
>You're right.
>
>The required byte count is returned in *prefsSize. The function return
>value is either noPreferenceFound or the prefs version number.
>
>The number of bytes copied to *prefs is the min of *prefsSize input
>and output values.
>
>-- Patrick
>
>

Which is one reason to call it twice.  The first time pass NULL as *prefs,
just to get the size of the data being stored back in *prefsSize.  Then you
can allocate the right amount of data & call it again w/ the pointer to the
newly allocated block.


--
-Richard M. Hartman
[EMAIL PROTECTED]

186,000 mi/sec: not just a good idea, it's the LAW!





-- 
For information on using the ACCESS Developer Forums, or to unsubscribe, please 
see http://www.access-company.com/developers/forums/

Reply via email to