mg2017
02/12/2021, 4:10 PMSandii
02/12/2021, 4:31 PMPage Init
, thats when the page is being loaded and does not seem to have anything to do with your scenario. However, validateLine
should trigger when the line is added. sublistChanged
probably would as well but I doubt you would get the line number passed in that case.Sandii
02/12/2021, 4:32 PMcommitLine
would be the like for like action.mg2017
02/12/2021, 4:48 PMSandii
02/12/2021, 4:49 PMSandii
02/12/2021, 4:51 PMselectNewLine
, setCurrentSublistValue
, and commitLine
should do it. If they aren't then you may need to make sure you forceSyncSourcing
or you are not filling out some part of the line that is required.mg2017
02/12/2021, 5:50 PMif (item) {
currentRecord.selectNewLine({
sublistId: 'item'
});
currentRecord.setCurrentSublistValue({
sublistId: 'item',
fieldId: 'item',
value: item
});
currentRecord.commitLine({
sublistId: "item"
});
}
That inserts the line but doesn't 'add' the linemg2017
02/12/2021, 5:53 PMmg2017
02/12/2021, 5:54 PMSandii
02/12/2021, 6:22 PM