InsertEx

ACCPAC Common Controls

AccpacView.InsertEx

Creates a new record in the database from the contents of the current logical record. This method is a network optimized version of Insert. It allows field values to be set to the view before the operation, and also returns field values of the requested fields, as well as the record number.

Sub InsertEx(
PutFieldIDs As Variant,
PutFieldValues As Variant,
GetFieldIDs As Variant,
GetFieldValues As Variant,
RecNum As Long)

Parameters

PutFieldIDs

[in] an array of field IDs representing the fields for which the values should first be modified before performing record fetching; the new values are specified in the PutFieldValues parameter

PutFieldValues

[in] an array of field values that should first be set to the view before performing record fetching; the values should appear in the array in the same order as the corresponding field IDs specified in the PutFieldIDs parameter

GetFieldIDs

[out] returns an array of field IDs representing the fields for which the values should be returned if a record is successfully retrieved

GetFieldValues

[out] returns an array of field values for the requested fields

RecNum

[out] returns the record number if a record is retrieved

Remarks

This method calls BlkPut (on PutFieldValues), and then Insert, and finally BlkGet (into GetFieldValues) to retrieve the field values. The record number is also retrieved.