Avatar

Level 2

Thanks for all of your help.

I'm sorry but I don't think I am following you a 100% as I've added row1 and buttons per your last post but it is not working.

var cMsg = "Continuing with the current action will remove all cell entries for this row";

cMsg += "\n\nDo you want to continue?";

var nRtn = app.alert(cMsg,1,1,"Question Alert Box");

if (nRtn == 1) {

// OK Response

if ( Table1._Item.count > 1 ) {

Table1._Item.removeInstance(this.row1.buttons.index);

console.println("The Response Was " + nRtn + ". (1 is OK.)");

}

} else if ( nRtn == 2 ) {

// Cancel Response

console.println("The Response Was " + nRtn + ". (2 is Cancel.)");

} else {

//Unknown Response

console.println("The Response Was somthing other than Yes/No: " + nRtn);

}

The screen shot below shows how I have the table set up. 


The first gray row cell in the table has the following:

form1.FSE_1.Row1.Table1.Item.ItemIndex::calculate - (JavaScript, both)

(this.parent.index + 1) + "PRE";

The Add button has:
Table1._Item.addInstance(0);

The original remove button has:

if (Table1._Item.count > 1)

  Table1._Item.removeInstance(Table1._Item.count - 1);

Capture111.PNG