On Wed, 15 May 2002, Joe wrote:
> When you use FtrGet,
> Err FtrGet (UInt32 creator, UInt16 featureNum, UInt32 *valueP)

  FtrGet retrieves a 32-bit integer that you store previously using FtrSet.

> A)
>   UInt32 foo;
>   SomeDataType value;
>   UInt32 size = sizeof(SomeDataType);
>   err = FtrGet( appFileCreator, ftrNum, (UInt32 *) &foo );
>   if ( !err )
>     MemMove( (void *) &value, (void *)foo, size );

  depends on what the value of foo is.. :)

> B)
>   SomeDataType value;
>   err = FtrGet( appFileCreator, ftrNum, (UInt32 *) &value );

  this will only work if SomeDataType = 32 bits :)

  normally, you use as follows:

    // get the data
    SomeDataType *value;
    err = FtrGet(appFileCreator, ftrNum, (UInt32 *)value);

  and you store as:

    // set the data
    SomeDataType value;
    err = FtrSet(appFileCreator, ftrNum, (UInt32)&value);

  normally, you set once.. and, get many times :) it depends what you
  are using the feature for :P got the idea? i believe my sample code
  (cube3d/burning) use features..

// az
[EMAIL PROTECTED]
http://www.ardiri.com/


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

Reply via email to