Interface IInsertRecordEvent
Insert record event information.
Inherited Members
Namespace: Attachmate.Verastream.HostIntegrator.ScriptAPI
Assembly: Attachmate.Verastream.HostIntegrator.ScriptAPI.dll
Syntax
public interface IInsertRecordEvent : IRecordSetEvent, IEntityEvent, IHostSessionEvent, IModelEvent, IEvent
Remarks
Insert record event information. See InsertRecord(IInsertRecordEvent)
Properties
CurrentRecordSetScreen
Fetches all records (including blank, repeated, filtered etc) on the current screen.
Declaration
IRecordSetScreen CurrentRecordSetScreen { get; }
Property Value
Type | Description |
---|---|
IRecordSetScreen | The records on the current screen. |
Remarks
This is useful for finding the correct insertion location in the recordset.
Exceptions
Type | Condition |
---|---|
ApptrieveException | Throws a Attachmate.Verastream.HostIntegrator.ScriptAPI.ApptrieveException if there is any error. |
FieldWriteValues
Gets the set of fields and associated values to be written.
Declaration
IDictionary<string, string> FieldWriteValues { get; }
Property Value
Type | Description |
---|---|
IDictionary<string, string> | A map of field names to field values. |
Remarks
The values in the map can be modified and the map used as a parameter to the DefaultInsertRecord(IDictionary) method.
Methods
DefaultInsertRecord()
Searches for suitable record as defined in the model, executes the before insert operation, writes the fields, and executes the after insert operation.
Declaration
void DefaultInsertRecord()
Remarks
Searches for suitable record as defined in the model, executes the before insert operation, writes the fields, and executes the after insert operation. The field values returned by GetFieldWriteValues() will be used.
Exceptions
Type | Condition |
---|---|
ApptrieveException | Throws a Attachmate.Verastream.HostIntegrator.ScriptAPI.ApptrieveException if there is any error. |
DefaultInsertRecord(IDictionary<string, string>)
Searches for suitable record as defined in the model, executes the before insert operation, writes the fields and executes the after insert operation.
Declaration
void DefaultInsertRecord(IDictionary<string, string> fieldValues)
Parameters
Type | Name | Description |
---|---|---|
IDictionary<string, string> | fieldValues | The fields and values to insert. |
Exceptions
Type | Condition |
---|---|
ApptrieveException | Throws a Attachmate.Verastream.HostIntegrator.ScriptAPI.ApptrieveException if there is any error. |
FindInsertLocation()
Search for a suitable insertion location as defined in the model and make that the current record.
Declaration
void FindInsertLocation()
Exceptions
Type | Condition |
---|---|
ApptrieveException | Throws a Attachmate.Verastream.HostIntegrator.ScriptAPI.ApptrieveException if there is any error. |
SetCurrentRecordIndex(int)
Sets the current record index.
Declaration
void SetCurrentRecordIndex(int index)
Parameters
Type | Name | Description |
---|---|---|
int | index | @param index one-based record index (zero meaning set the index to before the first record in the recordset) |
Remarks
Unlike IHostSession.SetCurrentRecordIndex, this method allows excluded records to be set as the current record. Any excluded record made current via this method has the excluded flag cleared, thus becoming visible to the client application.
Exceptions
Type | Condition |
---|---|
ApptrieveException | Throws a Attachmate.Verastream.HostIntegrator.ScriptAPI.ApptrieveException if there is any error. |
WriteField(string, string)
Writes the specified field to the current record on the screen.
Declaration
void WriteField(string name, string fieldValue)
Parameters
Type | Name | Description |
---|---|---|
string | name | The field name. |
string | fieldValue | The field value. |
Remarks
If the cursor is not at the field's location, the VHI will issue a MoveCursor command. Upon successfully moving the cursor, the value will be written to the screen, firing the appropriate WriteField(IWriteFieldEvent) event, if any.
Exceptions
Type | Condition |
---|---|
ApptrieveException | Throws a Attachmate.Verastream.HostIntegrator.ScriptAPI.ApptrieveException if there is any error. |