If you want to remove the last one why not use the count method on the instance Manager. This will give you a count of subforms that are displayed (it is 1 based), then subtract 1 to get the instance number for the last subform.
nNumSub = Subform1.Subform2.SubformImpression.instanceManager.count
That script does nothing as a replacement script or added to my original script.
It still deletes instances starting at the top.
Perhaps I missed something.
EDIT: Added the -1 to the end of it and worked perfectly when added in parenthesis to my original script.
Thanks again Paul.
So I want to do the same thing, but my instance manager set-up is much simpler:
So what code would I use to have a button that removes the last instance added?
Also, I want the instances to continue on to several pages if needed (i.e.: my outlay is just a small sample and one can add as many additional information layers as they need). But it all goes awray as it comes to the buttom of the first page. So I can I assure that as you click the add additional info, it will persist to as many pages as needed?
Thanks. I can send you the form if you need me too, since there is no upload anymore to this forum.
Paul has helped me with issue. Here's the code.
To make your table continues to second page, Make sure your form is Dynamic and set to Flowed.