Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Who Me Too'd this topic

Avatar

Level 5

I have an expanding table which will be used to enter a list of user names.  Each row has a "Remove User" button in the last cell on the right.  At the top of the table I have an "Add More Users" button.  I would like to hide the "Remove User" button when when the form is first opened or if there is only one user. Then after you click "Add More Users" I would like the button to start showing on all rows, including the first.  I'd greatly appreciate any help.

Table crop.jpg

The Add More Users button has this script, but it isn't working right:


if (RowUserName.RemoveUser.presence = "visible") {


  this.resolveNode('Table1._RowUserName').addInstance(1);


  }


  else


  RowUserName.RemoveUser.presence = "visible";


  this.resolveNode('Table1._RowUserName').addInstance(1);






I also tried using a small rectangle to block the label on the first button ("BlockLabelOnFirstButton"), but that doesn't work either (it completely disables the "Add New Users" button):


this.resolveNode("BlockLabelOnFirstButton").presence = "invisible";


this.resolveNode('Table1._RowUserName').addInstance(1);


if (xfa.host.version < :smiling_face_with_sunglasses: {


  xfa.form.recalculate(1);


  }


if (RowUserName.instanceManager.count = 1)


  {


  this.resolveNode("BlockLabelOnFirstButton").presence = "visible";


  }


Who Me Too'd this topic