Thanks very much Joe, I've managed to solve the problem thanks to you ^_^ I've just 
another small problem which I can't figure out again, hope someone can help me out. 
I've done the following changes:

static Err AppStart(void)
{
        const char *kName = "Test";
        const char *kTag = "Excerise";
        const int kCardNumber = 0;
        Err             err;  
        LocalID dbID, dBID;
        
        dbID = DmFindDatabase(kCardNumber, kTag);
                if(!dbID)
                //Alert here
                err = dmErrCantFind;
                else {
                ref = DmOpenDatabase(kCardNumber, dbID, dmModeReadOnly);

                if(ref == NULL)
                err = dmErrCantOpen;
        }

dBID = DmFindDatabase(kCardNumber, kName);
                if(!dBID)
                // Alert here
                err = dmErrCantFind;
                else {
                gDatabase = DmOpenDatabase(kCardNumber, dBID, dmModeReadOnly);

                if(gDatabase == NULL)
                err = dmErrCantOpen;
        
        }
   return err;
}

However, I can't call a Alert in the above. I don't know the reason. Perhaps someone 
can guide me pls?


___________________________________________________
Communicate with others using Lycos Mail for FREE!
http://mail.lycos.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