SBM AppScript Reference → Programming SBM AppScript → Extension Functions → Ext.CreateProjectBasedRecord( tableId )
This function is similar to Ext.CreateAppRecord( tableId [, recType] ), except the objects returned are of the subtype ProjectBasedRecord, and thus it may only be used on Primary tables. It is a runtime error to call this function on a non-Primary table. Objects created with this function do not support access to system table fields. All variable fields can be read and written by name.
When called on the Incidents table, the new object is an incident internally, though it is presented as the base type ProjectBasedRecord. Since the Incident object type offers no additional properties or methods beyond the ProjectBasedRecord type, all functionality is available. The Incident object type exists only for convenience; objects of type Incident can be created using CreateObject("SBM.Incident") without looking up the Primary table ID for the Incident Management application. They are otherwise identical to ProjectBasedRecord objects.
tableId
Pass this argument to create a new ProjectBasedRecord object of a subtype appropriate for the database table given by the number tableId.
The newly-created ProjectBasedRecord object containing a field list with all variable fields defined for the given table. The fields are created empty and can be written to individually or populated for a specific item using the Read() method. The returned object supports all functionality for a Primary table item.
Copyright © 2007–2019 Micro Focus or one of its affiliates. All rights reserved.