>   Okay, a more basic question:  how do I set the backup attribute bit?
> I'm guessing I need to change a bit in the attributes UInt passed into
>DmSetDatabaseInfo(), but I can't find information about which bit
>represents what in the API documentation.  So which bit do I need to set?

Here's what we use. It also set the copy prevention bit.

Regards,
Steve Mann

# # #

void SetDBMSDirty (  DmOpenRef DBref ) {

UInt    cardNo;
LocalID         dbID;
Err     error;
UInt    attr;

if ( ! DmOpenDatabaseInfo ( DBref, &dbID, NULL, NULL, &cardNo, NULL)) {
    if ( ! DmDatabaseInfo ( cardNo, dbID, NULL, &attr, NULL, NULL, NULL,
        NULL, NULL, NULL, NULL, NULL, NULL )) {
            attr = attr | dmHdrAttrBackup | dmHdrAttrCopyPrevention;
            error = DmSetDatabaseInfo ( cardNo, dbID, NULL, &attr, NULL,
NULL, NULL,
                NULL, NULL, NULL, NULL, NULL, NULL );
            if ( error > 0 ) DO SOMETHING
        } else DispErrMessage ( SOME ERROR );
    } else DispErrMessage ( SOME OTHER ERROR );
}


-------------------------------------------
Creative Digital Publishing Inc.
1315 Palm Street, San Luis Obispo, CA 93401-3117
-------------------------------------------
805.788.0138              805.593.3811 (fax)
[EMAIL PROTECTED]       http://www.cdpubs.com


Reply via email to