Err SendDatabase (UInt16 cardNo, LocalID dbID, const Char *nameP, const Char
*descriptionP)
{
 ExgSocketType  exgSocket;
 Err     err;

 // Create exgSocket structure
 MemSet(&exgSocket, sizeof(exgSocket), 0);
 exgSocket.description = const_cast<char*>(descriptionP);
 exgSocket.name = const_cast<char*>(nameP);
 exgSocket.target = 'lnch';
 exgSocket.count = 1;

 // Start and exchange put operation
 err = ExgPut(&exgSocket);
 if (!err)
  {
  // This function converts a palm database into its external (public)
  // format. The first parameter is a callback that will be passed parts of
  // the database to send or write.
  err = ExgDBWrite(WriteDBData, &exgSocket, NULL, dbID, cardNo);
  // Disconnect Exg and pass error
  err = ExgDisconnect(&exgSocket, err);
  }
 return err;
}



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

Reply via email to