home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 5 / 05.iso / a / a006 / 2.ddi / CEXAM.ZIP / TBLUNLCK.C < prev    next >
Encoding:
C/C++ Source or Header  |  1991-03-11  |  550 b   |  25 lines

  1. #include <stdio.h>
  2. #include "pxengine.h"
  3.  
  4. #define TABLENAME        "table"
  5. #define NETDIR           ""
  6. #define NETTYPE          NOTONNET
  7.  
  8. int main(void)
  9. {
  10.     TABLEHANDLE tblHandle;
  11.     int pxErr;
  12.  
  13.     PXNetInit(NETDIR,NETTYPE,DEFUSERNAME);
  14.     PXTblOpen(TABLENAME, &tblHandle, 0, 0);
  15.     PXNetTblLock(tblHandle, FL);
  16.  
  17.     /* Remove full-lock from a table */
  18.     if ((pxErr = PXNetTblUnlock(tblHandle, FL)) != PXSUCCESS)
  19.         printf("%s\n", PXErrMsg(pxErr));
  20.  
  21.     PXTblClose(tblHandle);
  22.     PXExit();
  23.     return(pxErr);
  24. }
  25.