Hello,
I created a button that will show/hide a subform. The issue is I need multiple buttons like this. I thought changing the name of the subform in this script would allow me to use another button for a different subform. For instance, Instead of using the word Alabama I could replace it with Alaska and it would show/hide that subform. Could having multiple pages in a subform affect its functionality? Please Help!
// Invoke the Instance Manager to add and remove the alabama subform.
if (fAlabama.value == "0") { // fAlabama is a document variable used as a flag.
// fAlabama = 1 when the alabama subform is displayed.
_alabama.setInstances(1); // Add the comments subform.
this.resolveNode("caption.value.#text").value = "Clear Alabama"; // Change the button's caption.
fAlabama.value = "1"; // Set the flag value.
}
else {
_alabama.setInstances(0); // Remove the alabama subform.
this.resolveNode("caption.value.#text").value = "Add Alabama"; // Change the button's caption.
fAlabama.value = "0"; // Reset the flag value.
}
Thanks,
Venus