01-12-2022 01:57 PM - last edited on 05-24-2023 12:32 PM by JackLacava
SOURCE: ONESTREAM CHAMPIONS
Hi Friends,
Did anyone try inserting rows into a custom table ( within one stream ) using Spread Sheet?
I am able to update the data into the custom table, but somehow the basic functions like insert didn’t work for me.
I need a similar function as per the screenshot for identifying the new records and the existing records.
Regards and Thanks
Darpan Bhansali
01-12-2022 01:57 PM
Any Thoughts to be shared?
01-12-2022 01:58 PM
You need to create the spreadsheet rule that allows inserting. You can enable how many insert rows need to be provided as well. I use the status column feature to perform INSERT, UPDATE, and DELETE operations.
01-12-2022 01:59 PM
Hi Celvin, thanks… i can understand what you spoke above… but unable to write the code… if possible can you please share the code which you used.
that will be of great help
Regards
Darpan Bhansali
01-12-2022 02:01 PM
Hi,
do you have the “Table Views User Guide” available?
On page 14 there is an example helper similar to his code:
Dim tableView As New TableView()
tableView.CanModifyData = True
tableView.NumberOfEmptyRowsToAdd = 5
tableView.EmptyRowsBackgroundColor = XFColors.LightGray
The addition of tableview.EnableStatusColumn(True, statusColumnName, “DELETE,ARCHIVE, INACTIVE”) is described on the following pages of the same guide.
The final area is where the operations could be set
If the statusColumnName is not declared there is an automated/default naming of that column when left blank. “DELETE, ARCHIVE, INACTIVE” could show those choices in the drop down of the Spreadsheet Table View. A key requirement is to set ‘CanModifyData’ to True.
For the exact code combination that needs to be associated with status in your case, I will leave this question to your service providers