home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 Mobile / Chip_Mobile_2001.iso / palm / tools / hotsyncn / hotsyncn.exe / hotsyncname.c next >
Encoding:
C/C++ Source or Header  |  2000-11-20  |  681 b   |  38 lines

  1. #include <PalmOS.h>
  2. #include <DLServer.h.>
  3.  
  4. UInt32 PilotMain(UInt16, MemPtr, UInt16);
  5. Err startApplication(void);
  6.  
  7. Err startApplication()
  8. {
  9.     MemHandle nameH;
  10.     Char *nameP;
  11.  
  12.     nameH = MemHandleNew(dlkMaxUserNameLength + 1); 
  13.     nameP = MemHandleLock(nameH); 
  14.     StrCopy(nameP, "");
  15.     DlkGetSyncInfo(NULL, NULL, NULL, nameP, NULL, NULL);
  16.     nameP[dlkMaxUserNameLength] = 0;
  17.     FrmCustomAlert(1000, nameP, " ", " ");
  18.     MemHandleUnlock(nameH);
  19.     return errNone;
  20. }
  21.  
  22. UInt32 PilotMain(UInt16 cmd, MemPtr cmdPBP, UInt16 launchFlags)
  23. {
  24.     UInt32 result = 0;
  25.     
  26.     switch (cmd) 
  27.     {
  28.         case sysAppLaunchCmdNormalLaunch:
  29.             startApplication();
  30.             return -1;
  31.             break;
  32.  
  33.         default:
  34.             break;
  35.     }
  36.     return result;
  37. }
  38.