QMWriteuSeqKey()

QMWriteuSeqKey()

Top  Previous  Next

 

The QMWriteuSeqKey() function writes a record using an automatically generated sequential numeric key. This is analogous to use of the CREATING.SEQKEY option of the QMBasic WRITEU statement.

 

The function arguments are:

 

FileNois the file number returned by a previous QMOpen() call.

 

Idis the id of the record.

 

Recis the data to be written to this record.

 

 

The QMWriteuSeqKey() function writes the given data to the hashed file opened as FileNo. The record id is automatically generated and returned as the value of this function. This operation is not valid for directory files or distributed files.

 

An update lock is automatically applied to this record for the duration of the internal processing of the write and retained on return from the function.

 

The example program fragments below write the data in ClientRec to the file open as fCLients. The record id is generated automatically and returned in the Id variable.

 

 

hmtoggle_plus1C

 

hmtoggle_plus1VB.Net

 

hmtoggle_plus1QMBasic Class Module

 

hmtoggle_plus1Java

 

hmtoggle_plus1Python