Ask our Experts
Didn't find what you are looking for? Ask our experts!
Launch of Consumer/Home Owner registration process! We are pleased to announce the commencement of the Consumer/Home Owner Registration Process on Community. Consumers/Home Owners may now proceed to register by clicking on Login/Register. The process is straightforward and designed to be completed in just a few steps.
Schneider Electric support forum about installation, configuration, integration and troubleshooting of EcoStruxure Geo SCADA Expert (ClearSCADA, ViewX, WebX).
Search in
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-09-17 12:13 AM . Last Modified: 2023-05-03 12:10 AM
Hi,
from the schema for CDBObject I see the below.
AddRecord Add Row Adds a new record to a data table. Control [retval] Record (Long) : Record ID of the new record in the data table.
The below code works. However, I thought I would be able to use - obj.Interface.AddRecord(RecordId); to return the record id of the new record.
But, it does not allow me. Unless I am going about the syntax wrong? Thanks,
obj.Interface.AddRecord();
RecordId = obj.Interface.RecordCount(RecordId);
RecordId = RecordId - 1;
obj.Interface.SetValue("TestField", RecordId, "Test");
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-09-17 03:02 AM
The correct syntax is:
RecordId = obj.Interface.AddRecord();
obj.Interface.SetValue("TestField", RecordId, "Test");
The record ID is returned by the AddRecord() method.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2020-09-17 03:02 AM
The correct syntax is:
RecordId = obj.Interface.AddRecord();
obj.Interface.SetValue("TestField", RecordId, "Test");
The record ID is returned by the AddRecord() method.
Link copied. Please paste this link to share this article on your social media post.
You’ve reached the end of your document
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.