How to capture Table Add Row event?

Hi Team,

I would like to update/set the one of the cell value as default based on item type added under the CO–>Affected Items table

when user tries to add a item/row to the affected items tables , system should automatically update the one of the cell value?

not sure how to capture rows add event on table?

IUpdateTableEventInfo  i think this one only triggers when  cell value is modified.

Add Comment
1 Answer(s)

Here’s how I do it with IUpdateTableEventInfo for attachments but would work similar for Affected Items table.  Note the Event Action specifies to do something if its EventConstants.DIRTY_ROW_ADD_ROW.  Another UpdateTable event will be triggered when you update the cell you want to set, but I think that would give a DIRTY_ROW_UPDATE_ROW event action


IUpdateTableEventInfo info = (IUpdateTableEventInfo) event;
IObjectEventInfo ioeInfo = (IObjectEventInfo) event;
IEventDirtyTable edt = info.getTable();
Iterator<?> it = edt.iterator();
while (it.hasNext()) {
     IEventDirtyRow aRow = (IEventDirtyRow);
     if (aRow.getAction() == EventConstants.DIRTY_ROW_ACTION_ADD_FILE || aRow.getAction() == EventConstants.EVENT_CHECK_IN_FILES) {
          IDataObject ido = info.getDataObject();
//Set your cell value here against the ido
} else {

Agile Talent Answered on March 3, 2023.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.