/* Copyright (c) 1990 by Borland International, Inc. */ #ifndef PXENGINE_H #define PXENGINE_H #define InternalVersion 0x01011201L /* version number, same */ /* as found in .lib files */ /* Type definitions */ typedef unsigned TABLEHANDLE; /* table handle */ typedef unsigned RECORDHANDLE; /* record handle */ typedef unsigned FIELDHANDLE; /* field number 1.. */ typedef int LOCKHANDLE; /* lock handle */ typedef long RECORDNUMBER; /* record number 1.. */ /* Maximum and default values for dynamic configuration. */ /* The default values are used if not overwritten in PXSetDefaults */ #define PXDEFAULT 0L /* use internal default value */ #define MAXTABLEHANDLES 64 /* maximum number of open */ /* tables allowed at a time */ #define DEFTABLEHANDLES 5 /* default number of open */ /* tables allowed at a time */ #define MAXRECORDHANDLES 128 /* maximum number of record */ /* buffers available */ #define DEFRECORDHANDLES 10 /* default number of record */ /* buffers available */ #define MAXLOCKHANDLES 128 /* maximum number of lock */ /* handles per table */ #define DEFLOCKHANDLES 32 /* default number of lock */ /* handles per table */ #define MAXFILEHANDLES 255 /* maximum number of DOS file */ /* handles to use */ #define MINFILEHANDLES 2 /* minimum number of DOS file */ /* handles to use */ #define DEFFILEHANDLES 10 /* default number of DOS file */ /* handles to use */ #define DEFSORTORDER (char *) -1 /* default sort order (ASCII) */ /* Swap buffer size */ #define MAXSWAPSIZE 256 /* maximum buffer size allowed (k)*/ #define MINSWAPSIZE 8 /* minimum buffer size allowed (k)*/ #define DEFSWAPSIZE 32 /* default buffer size (k) */ /* Network codes */ /* used in PXNetInit */ #define NOTONNET 1 /* not on a net */ #define NOVELLNET 2 /* Novell */ #define THREECOMNET 3 /* 3Com */ #define IBMPCNET 4 /* IBM PC */ #define OTHERNET 5 /* other: unknown DOS 3.1 compatible */ #define TORUSNET 6 /* Torus (version 1.4) */ #define STARLANNET 7 /* Starlan */ #define BANYANNET 8 /* Banyan */ #define LOCALSHARE 32 /* enables sharing on local drives with */ /* any net type */ /* (i.e. OTHERNET | LOCALSHARE) */ #define DEFUSERNAME NULL /* use default username in PXNetInit() */ /* used in PXKeyAdd */ #define PRIMARY 0 /* primary index (key) */ #define SECONDARY 1 /* not maintained secondary index */ #define INCSECONDARY 2 /* maintained secondary index */ /* used in PXSrchFld, PXSrchKey */ #define SEARCHFIRST 0 /* search from beginning of table */ #define SEARCHNEXT 1 /* search from next record in table */ #define CLOSESTRECORD 2 /* (modifier) goto 'nearest' record if */ /* no match found (ordered fields only) */ /* Lock types */ /* used in PXNetFileLock, PXNetFileUnlock, PXNetTblLock, PXNetTblUnlock */ #define FL 1 /* full lock, no concurrency */ #define WL 2 /* write lock */ #define PWL 3 /* prevent write lock */ #define PFL 4 /* prevent full lock, full concurrency */ /* commonly used constants */ #ifndef TRUE #define TRUE 1 #endif /* TRUE */ #ifndef FALSE #define FALSE 0 #endif /* FALSE */ #ifndef NULL #define NULL 0L #endif /* NULL */ /* macros for checking blank values */ #define ISBLANKALPHA(x) ((x)[0] == 0x0) #define ISBLANKSHORT(x) ((unsigned)(x) == 0x8000) #define ISBLANKLONG(x) ((unsigned long)(x) == 0x80000000L) #define BLANKDATE 0x80000000L #define BLANKLONG 0x80000000L #define BLANKSHORT 0x8000 /* successful Engine function operation returns */ #define PXSUCCESS 0 /* errorcodes from Engine functions */ /* initialization errors */ #define PXERR_NOTINITERR 78 /* Engine not initialized */ #define PXERR_ALREADYINIT 82 /* Engine already initialized */ #define PXERR_NOTLOGGEDIN 98 /* Could not login on network */ /* (to PARADOX.NET) */ #define PXERR_NONETINIT 107 /* Engine not initialized */ /* with PXNetInit */ #define PXERR_NETMULTIPLE 15 /* multiple PARADOX.NET files */ /* hardware related errors */ #define PXERR_DRIVENOTREADY 1 /* Drive not ready */ #define PXERR_DISKWRITEPRO 124 /* Disk is write protected */ #define PXERR_GENERALFAILURE 126 /* General hardware error */ /* directory reg error codes */ #define PXERR_DIRNOTFOUND 2 /* Directory not found */ #define PXERR_DIRBUSY 10 /* Sharing violation */ #define PXERR_DIRLOCKED 11 /* Sharing violation */ #define PXERR_DIRNOACCESS 12 /* No access to directory */ #define PXERR_DIRNOTPRIVATE 14 /* Single user, but directory is*/ /* shared */ /* file oriented errors */ #define PXERR_FILEBUSY 3 /* File is busy */ #define PXERR_FILELOCKED 4 /* File is locked */ #define PXERR_FILENOTFOUND 5 /* Could not find file */ /* table oriented errors */ #define PXERR_TABLEBUSY 118 /* Table is busy */ #define PXERR_TABLELOCKED 119 /* Table is locked */ #define PXERR_TABLENOTFOUND 120 /* Table was not found */ #define PXERR_TABLEOPEN 83 /* Unable to perform operation */ /* on open table */ #define PXERR_TABLEINDEXED 94 /* Table is indexed */ #define PXERR_TABLENOTINDEXED 95 /* Table is not indexed */ #define PXERR_TABLEEMPTY 105 /* Operation on empty table */ #define PXERR_TABLEWRITEPRO 22 /* Table is write protected */ #define PXERR_TABLECORRUPTED 6 /* Table is corrupted */ #define PXERR_TABLEFULL 128 /* Table is full */ #define PXERR_INSUFRIGHTS 21 /* Insufficient password rights */ /* index oriented errors */ #define PXERR_XCORRUPTED 7 /* Primary index is corrupted */ #define PXERR_XOUTOFDATE 8 /* Primary index is out of date */ #define PXERR_XSORTVERSION 13 /* Sort for index different */ /* from table */ #define PXERR_SXCORRUPTED 122 /* Secondary index is corrupted */ #define PXERR_SXOUTOFDATE 96 /* Secondary index is out of date*/ #define PXERR_SXNOTFOUND 121 /* Secondary index was not found */ #define PXERR_SXOPEN 123 /* Secondary index is already open*/ #define PXERR_RECTOOBIG 125 /* Record too big for index */ /* record oriented errors */ #define PXERR_RECDELETED 50 /* Another user deleted record */ #define PXERR_RECLOCKED 9 /* Record is locked */ #define PXERR_RECNOTFOUND 89 /* Record was not found */ #define PXERR_KEYVIOL 97 /* Key violation */ #define PXERR_ENDOFTABLE 101 /* End of table */ #define PXERR_STARTOFTABLE 102 /* Start of table */ /* resource errors */ #define PXERR_OUTOFMEM 40 /* Not enough memory to */ /* complete operation */ #define PXERR_OUTOFDISK 41 /* Not enough disk space to */ /* complete operation */ #define PXERR_OUTOFSTACK 127 /* Not enough stack space to */ /* complete operation */ #define PXERR_OUTOFSWAPBUF 129 /* Not enough swap buffer space to*/ /* complete operation */ #define PXERR_OUTOFFILEHANDLES 70 /* No more file handles available*/ #define PXERR_OUTOFTABLEHANDLES 72 /* No more table handles available*/ #define PXERR_OUTOFRECHANDLES 103 /* No more record handles available*/ #define PXERR_OUTOFLOCKHANDLES 111 /* Too many locks on table */ #define PXERR_NOMORETMPNAMES 86 /* No more temporary names */ /* available */ #define PXERR_TOOMANYPASSW 115 /* Too many passwords specified */ /* invalid parameters to functions */ #define PXERR_TYPEMISMATCH 30 /* Data type mismatch */ #define PXERR_OUTOFRANGE 31 /* Argument out of range */ #define PXERR_INVPARAMETER 33 /* Invalid argument */ #define PXERR_INVDATE 73 /* Invalid date given */ #define PXERR_INVFIELDHANDLE 75 /* Invalid field handle */ #define PXERR_INVRECHANDLE 104 /* Invalid record handle */ #define PXERR_INVTABLEHANDLE 76 /* Invalid table handle */ #define PXERR_INVLOCKHANDLE 110 /* Invalid lock handle */ #define PXERR_INVDIRNAME 114 /* Invalid directory name */ #define PXERR_INVFILENAME 108 /* Invalid file name */ #define PXERR_INVTABLENAME 99 /* Invalid table name */ #define PXERR_INVFIELDNAME 74 /* Invalid field name */ #define PXERR_INVLOCKCODE 106 /* Invalid lock code */ #define PXERR_INVUNLOCK 109 /* Invalid unlock */ #define PXERR_INVSORTORDER 112 /* Invalid sort order table */ #define PXERR_INVPASSW 116 /* Invalid password */ #define PXERR_INVNETTYPE 113 /* Invalid net type (PXNetInit) */ #define PXERR_BUFTOOSMALL 117 /* Buffer too small for result */ #define PXERR_STRUCTDIFFER 81 /* Table structures are different*/ #define PXERR_INVENGINESTATE 79 /* Previous fatal error; */ /* cannot proceed */ /*----------------------------------------------------------------------*/ /* prototypes for engine functions */ /* declarations of sort order tables, used in PXSetDefaults */ extern char * pascal SortOrderAscii; /* ASCII sort order */ extern char * pascal SortOrderIntl; /* international sort order */ extern char * pascal SortOrderNorDan; /* Norwegian/Danish sort order */ extern char * pascal SortOrderSwedFin; /* Swedish/Finnish sort order */ /* INITIALIZATION AND FINALIZATION FUNCTIONS */ /* initialize Engine */ int pascal PXInit(void); /* initialize Engine and net support */ int pascal PXNetInit( /* */ char *netNamePath, /* directory containing .NET file */ int netType, /* type of network */ char *userName); /* user name, as put in .NET file */ /* exit and deallocate */ int pascal PXExit(void); /* overwrites internal default values */ int pascal PXSetDefaults( /* */ int bufSize, /* internal swap buffer size */ /* MINSWAPSIZE..MAXSWAPSIZE (8..256), */ /* default DEFSWAPSIZE (32) */ /* allocated at initialization time */ int maxTables, /* max number of tables open at a time */ /* range 1..MAXTABLEHANDLES , (1..64) */ /* default DEFTABLEHANDLES (5) */ int maxRecBufs, /* max number of record buffers at a time*/ /* range 1..MAXRECORDHANDLES , (1..128)*/ /* default DEFRECORDHANDLES (10) */ int maxLocks, /* max number of locks per table */ /* range 1..MAXLOCKHANDLES , (1..128)*/ /* default DEFLOCKHANDLES (32) */ int maxFiles, /* max number of file handles to use */ /* range MINFILEHANDLES..MAXFILEHANDLES */ /* default DEFFILEHANDLES (10) */ char *sortOrder /* address of sort order table defined */ /* internally in the Engine : */ /* SortOrderAscii/SortOrderIntl/ */ /* SortOrderNorDan/SortOrderSwedFin */ /* default : SortOrderAscii */ ); /* returns current default settings */ int pascal PXGetDefaults( int *swapSize, /* returns internal swap buffer size */ int *maxTables, /* returns max number of tables at a time */ int *maxRecBufs, /* returns max number of record buffers */ int *maxLocks, /* returns max number of locks per table */ int *maxFiles, /* returns max number of file handles to use*/ char **sortTable /* returns address of default sort table */ ); /* enables/disables internal hardware error handler */ int pascal PXSetHWHandler( int hwHandler); /* enable(TRUE) / disable (FALSE) */ /* default TRUE */ /* TABLE FUNCTIONS */ /* open table for access, returning table handle */ int pascal PXTblOpen( /* */ char *tblName, /* name of table to open */ TABLEHANDLE *tblHandle, /* returns handle for opened table */ int indexID, /* =0 mastertable else indexnumber */ int saveEveryChange); /* save each record as it is changed */ /* don't buffer changes */ /* close access to table */ int pascal PXTblClose( /* */ TABLEHANDLE tblHandle); /* tblHandle of table to close */ /* create empty table */ int pascal PXTblCreate( /* */ char *tblName, /* name of table to create */ int nFields, /* number of fields in table */ char **fields, /* field names */ char **types); /* field types (N, S..) */ /* clear table for records */ int pascal PXTblEmpty( /* */ char *tblName); /* name of table to empty */ /* delete table and its family */ int pascal PXTblDelete( /* */ char *tblName); /* name of table to delete */ /* copy table and its family */ int pascal PXTblCopy( /* */ char *fromName, /* source table of copy */ char *toName); /* destination table of copy */ /* rename table and its family */ int pascal PXTblRename( /* */ char *fromName, /* source table of copy */ char *toName); /* destination table of copy */ /* add records from one table to another table */ int pascal PXTblAdd( /* */ char *srcName, /* source table of add */ char *destName); /* destination table of add */ /* RECORD FUNCTIONS */ /* insert record buffer in database (as last record if Heap) */ int pascal PXRecAppend( /* */ TABLEHANDLE tblHandle, /* table to append record to */ RECORDHANDLE recHandle );/* record to append */ /* insert record buffer in database (before current if Heap) */ int pascal PXRecInsert( /* */ TABLEHANDLE tblHandle, /* table to insert record into */ RECORDHANDLE recHandle);/* record to insert */ /* updates current record in database with contents of the record buffer*/ int pascal PXRecUpdate( /* */ TABLEHANDLE tblHandle, /* table to update record into */ RECORDHANDLE recHandle);/* changed record to post */ /* creates a record buffer for a table */ int pascal PXRecBufOpen( /* */ TABLEHANDLE tblHandle, /* table to create buffer for */ RECORDHANDLE *recHandle);/* returns handle to record buffer */ /* deletes a record buffer for a table */ int pascal PXRecBufClose( /* */ RECORDHANDLE recHandle);/* record buffer to remove */ /* clears the record buffer (to blanks) */ int pascal PXRecBufEmpty( /* */ RECORDHANDLE recHandle);/* record buffer to clear */ /* copy record from a record buffer to another (compatible) record buffer*/ int pascal PXRecBufCopy( /* */ RECORDHANDLE fromHandle,/* record buffer to copy from */ RECORDHANDLE toHandle); /* record buffer to copy to */ /* gets the current record from the database into the record buffer */ int pascal PXRecGet( /* */ TABLEHANDLE tblHandle, /* table to get record from */ RECORDHANDLE recHandle);/* record buffer to put record in */ /* FIELD FUNCTIONS */ /* put short value into N/$/S field in record buffer */ int pascal PXPutShort( /* */ RECORDHANDLE recHandle, /* record buffer to put value in */ FIELDHANDLE fldHandle, /* field in record */ short value); /* value to put */ /* put double value into N/$/S field in record buffer */ int pascal PXPutDoub( /* */ RECORDHANDLE recHandle, /* record buffer to put value in */ FIELDHANDLE fldHandle, /* field in record */ double value); /* value to put */ /* put long value into N/$/S field in record buffer */ int pascal PXPutLong( /* */ RECORDHANDLE recHandle, /* record buffer to put value in */ FIELDHANDLE fldHandle, /* field in record */ long value); /* value to put */ /* put string into Alpha field in record buffer */ int pascal PXPutAlpha( /* */ RECORDHANDLE recHandle, /* record buffer to put value in */ FIELDHANDLE fldHandle, /* field in record */ char *value); /* value to put */ /* put long value into date field (encoded value) in record buffer */ int pascal PXPutDate( /* */ RECORDHANDLE recHandle, /* record buffer to put value in */ FIELDHANDLE fldHandle, /* field in record */ long value); /* value to put */ /* put blank value into field in record buffer */ int pascal PXPutBlank( RECORDHANDLE recHandle, /* record buffer to put blank in */ FIELDHANDLE fldHandle); /* field in record */ /* get value from N/$/S field in record buffer, into short */ int pascal PXGetShort( /* */ RECORDHANDLE recHandle, /* record buffer to get value from */ FIELDHANDLE fldHandle, /* field to get value from */ short *Svalue); /* returns value */ /* get value from N/$/S field in record buffer, into double */ int pascal PXGetDoub( /* */ RECORDHANDLE recHandle, /* record buffer to get value from */ FIELDHANDLE fldHandle, /* field to get value from */ double *Dvalue); /* returns value */ /* get value from N/$/S field in record buffer, into long */ int pascal PXGetLong( /* */ RECORDHANDLE recHandle, /* record buffer to get value from */ FIELDHANDLE fldHandle, /* field to get value from */ long *Lvalue); /* returns value */ /* get string from alpha field in record buffer */ int pascal PXGetAlpha( /* */ RECORDHANDLE recHandle, /* record buffer to get value from */ FIELDHANDLE fldHandle, /* field to get value from */ int bufSize, /* size of return buffer */ char *dest); /* return buffer */ /* get value from date field in record buffer, into long (encoded value)*/ int pascal PXGetDate( /* */ RECORDHANDLE recHandle, /* record buffer to get value from */ FIELDHANDLE fldHandle, /* field to get value from */ long *value); /* returns value */ /* is value in specified field in record buffer a blank? */ int pascal PXFldBlank( /* */ RECORDHANDLE recHandle, /* record to test value in */ FIELDHANDLE fldHandle, /* field to test */ int *Blank); /* returns TRUE/FALSE */ /*----------------------------------------------------------------------*/ /* move to record with specified record number */ int pascal PXRecGoto( /* */ TABLEHANDLE tblHandle, /* tblHandle of table to move in */ RECORDNUMBER recNum); /* record number to move to */ /* move to first record in table */ int pascal PXRecFirst( /* */ TABLEHANDLE tblHandle); /* table to move in */ /* move to last record in table */ int pascal PXRecLast( /* */ TABLEHANDLE tblHandle); /* table to move in */ /* move to next record in table */ int pascal PXRecNext( /* */ TABLEHANDLE tblHandle); /* table to move in */ /* move to previous record in table */ int pascal PXRecPrev( /* */ TABLEHANDLE tblHandle); /* table to move in */ /* delete current record in table */ int pascal PXRecDelete( /* */ TABLEHANDLE tblHandle); /* table to delete record in */ /* INDEX FUNCTIONS */ /* add a primary or secondary (maintained/nonmaintained) index */ int pascal PXKeyAdd( /* */ char *tblName, /* name of table to add index for */ int nFlds, /* number of fields in index */ FIELDHANDLE *fldHandles,/* array of field numbers in index */ int mode ); /* type of index to create */ /* PRIMARY/SECONDARY/INCSECONDARY */ /* delete an index for a table (primary/secondary) */ int pascal PXKeyDrop( /* */ char *tblName, /* name of table to delete index for */ int indexID); /* 0 if primary key, else field number */ /* of secondary index */ /* DATE FUNCTIONS */ /* decodes a date value stored in the Paradox format */ int pascal PXDateDecode( long date, /* long value to decode */ int *mo, /* decoded month value */ int *da, /* decoded date value */ int *yr); /* decoded year value */ /* encodes a date value to a long value in Paradox format */ int pascal PXDateEncode( int mo, /* month value to encode */ int da, /* date value to encode */ int yr, /* year value to encode */ long *date); /* encoded date value */ /* SEARCH FUNCTIONS */ /* Searches a table for a given (sub) key */ int pascal PXSrchKey( TABLEHANDLE tblHandle, /* table to search in */ RECORDHANDLE recHandle, /* record buffer containing key to find */ int nFlds, /* number of fields in key */ int mode); /* searching from first/next record */ int pascal PXSrchFld( TABLEHANDLE tblHandle, /* table to search in */ RECORDHANDLE recHandle, /* record buffer containing field to find*/ FIELDHANDLE fldHandle, /* field number to search on */ int mode); /* searching from first/next record */ /* PASSWORD FUNCTIONS */ /* checks if table is encrypted */ int pascal PXTblProtected( /* */ char *tblName, /* name of table to check */ int *Protected); /* returns TRUE/FALSE */ /* enters a password to the Engine */ int pascal PXPswAdd( /* */ char *password); /* password to enter into system */ /* deletes a password previously entered */ int pascal PXPswDel( /* */ char *password); /* password to remove from system */ /* encrypt a table and make it password protected */ int pascal PXTblEncrypt( /* */ char *tblName, /* name of table to encrypt */ char *password); /* password for encrypted table */ /* decrypt a table, password must already have been entered */ int pascal PXTblDecrypt( /* */ char *tblName); /* name of table to decrypt */ /* INFORMATIONAL FUNCTIONS */ /* checks if table exists */ int pascal PXTblExist( /* */ char *tblName, /* name of table to check */ int *Exist) ; /* returns TRUE/FALSE */ /* returns table name corresponding to a table handle */ int pascal PXTblName( /* */ TABLEHANDLE tblHandle, /* table to return name of */ int bufSize, /* size of return buffer */ char *tblName); /* name of table, without extension */ /* returns record number of current record in table */ int pascal PXRecNum( /* */ TABLEHANDLE tblHandle, /* table to get record number from */ RECORDNUMBER *recnum); /* returns record number */ /* returns number of records in table */ int pascal PXTblNRecs( /* */ TABLEHANDLE tblHandle, /* table to get number of records from */ RECORDNUMBER *nRecs); /* returns number of records */ /* returns number of fields in a record */ int pascal PXRecNFlds( /* */ TABLEHANDLE tblHandle, /* table to get number of fields from */ int *nFlds); /* returns number of fields in a record */ /* return number of fields in key for table */ int pascal PXKeyNFlds( /* */ TABLEHANDLE tblHandle, /* table to get key size for */ int *nKeyFlds); /* returns number of fields in key */ /* returns field number of a given field name in a table */ int pascal PXFldHandle( /* */ TABLEHANDLE tblHandle, /* table to get field number from */ char *fieldName, /* name of field in table */ FIELDHANDLE *fldHandle);/* returns field number */ /* returns field type of a given field in a table */ int pascal PXFldType( TABLEHANDLE tblHandle, /* table to get field type from */ FIELDHANDLE fldHandle, /* field number of field in table */ int bufSize, /* size of return buffer */ char *fldType); /* field type of field as string */ /* returns field name of a given field in a table */ int pascal PXFldName( TABLEHANDLE tblHandle, /* table to get field name from */ FIELDHANDLE fldHandle, /* field number of field in table */ int bufSize, /* size of return buffer */ char *fldName); /* returns name of field */ /* MISCELLANEOUS FUNCTIONS */ /* sets maximum size of tables created with PXTblCreat() */ int pascal PXTblMaxSize( /* */ int maxsize); /* maximum size of table */ /* 64/128/256 (Megabytes) */ /* saves all buffered changes to disk */ int pascal PXSave(void); /* CONCURRENCY FUNCTIONS */ /* can be used only if PXNetInit() was called successfully */ /* returns name of user as known on network */ int pascal PXNetUserName( /* */ int bufSize, /* size of return buffer */ char *userName); /* returns user name */ /* locks a file with specified lock (general function) */ int pascal PXNetFileLock( /* */ char *fileName, /* name of file to lock */ int lockType); /* type of lock to put on file */ /* (FL, WL, PFL, PWL) */ /* unlocks a file with specified lock (general function) */ int pascal PXNetFileUnlock( /* */ char *fileName, /* name of file to unlock */ int lockType); /* type of lock to remove from file */ /* (FL, WL, PFL, PWL) */ /* locks an open table with specified lock */ int pascal PXNetTblLock( /* */ TABLEHANDLE tblHandle, /* table to lock */ int lockType); /* type of lock to put on table */ /* (FL, WL, PFL, PWL) */ /* unlocks an open table with specified lock */ int pascal PXNetTblUnlock( /* */ TABLEHANDLE tblHandle, /* table to unlock */ int lockType); /* type of lock to remove from table */ /* (FL, WL, PFL, PWL) */ /* locks the current record in a table */ int pascal PXNetRecLock( /* */ TABLEHANDLE tblHandle, /* table to lock record in */ LOCKHANDLE *lckHandle); /* returns handle to lock */ /* unlocks record associated with lock handle in the table */ int pascal PXNetRecUnlock( /* */ TABLEHANDLE tblHandle, /* table to unlock record in */ LOCKHANDLE lckHandle); /* lock handle of record to unlock */ /* checks if current record in table is locked (by any user) */ int pascal PXNetRecLocked( /* */ TABLEHANDLE tblHandle, /* table to check record in */ int *Locked); /* returns TRUE/FALSE */ /* moves to the record in the table associated with the lock handle */ int pascal PXNetRecGotoLock( /* */ TABLEHANDLE tblHandle, /* table to move in */ LOCKHANDLE lckHandle); /* lock handle to record */ /* checks if table was changed by other user since last refresh */ int pascal PXNetTblChanged( /* */ TABLEHANDLE tblHandle, /* table to test */ int *Changed); /* returns TRUE/FALSE */ /* forces a refresh of a table if it was changed by another user */ int pascal PXNetTblRefresh( /* */ TABLEHANDLE tblHandle); /* tabel to refresh */ /* ERROR FUNCTIONS */ /* returns error text associated with the error number */ char *pascal PXErrMsg( int errCode); /* errcode to return text for */ /* returns name of user causing a locking error */ int pascal PXNetErrUser( /* */ int bufSize, /* size of return buffer */ char *userName); /* returns user name */ #endif /* PXENGINE_H */