How to fetch a field value in repeatable panel or table row? | Community
Skip to main content
Level 2
Sep 30, 2019 11:32 AM UTC
Solved

How to fetch a field value in repeatable panel or table row?

We need a solution for an adaptive form - NOT a 'lifecycle' form...

We have a few tables that allow for the rows to be added (addInstance) and removed (removeInstance).  This all works.

What I want to do - is to also fetch/display/null the value of a certain filed within a specific instance of a repeatable row. 

For example: 

  • Row1[1].textfield.value=null;

or

  • alert(Row1[1].textfield.value);

Nothing I have tried seems to work - for instance, I have tried:

  • Row1.instanceManager.instances[1].textfield.value
  • guideBridge.resolveNodes("Row1[" + instanceCounter + "].tableItem11").value

Any ideas?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Mayank_Gandhi
Mayank_GandhiAccepted solution
Employee
Sep 30, 2019 12:16 PM UTC

Try this:

alert(panel1393766227897.instanceManager.instances[panel1393766227897.instanceIndex].textbox_0.value);

Where  panel1393766227897 is your repeatable panel and textbox_0 is the textbox.

Thanks,

Mayank

7 replies

Level 2
Sep 30, 2019 3:47 PM UTC

This worked.  Loving it.

~Thanks

Translate
Level 2
Sep 30, 2019 3:47 PM UTC

I am going to need to study GuideBridge(s) more.  Mayank's solution works for me - but the GuideBridge looks like something I may need in the future.

Translate
Employee
Sep 30, 2019 1:46 PM UTC

Using the guide bridge API resolveNode get hold of the repeatable panel object

from that panel object get the instanceManager

from the instance manager get the array of instances

and from that array get the value of your specific field

Translate
Mayank_Gandhi
Employee
Sep 30, 2019 1:44 PM UTC

Download and Check the sample from below link and let me know:

Adobe Document Cloud

Translate
Employee
Sep 30, 2019 1:40 PM UTC

Please refer to guide bridge api

Adaptive Forms Class: GuideBridge

Translate
Level 2
Sep 30, 2019 12:40 PM UTC

Sorry. that didn't work either.

Tried:

  • alert(Row1.instanceManager.instances[Row1.instanceIndex].tbcFirstNm[0].value);
  • alert(Row1.instanceManager.instances[0].tbcFirstNm[0].value);
  • alert(Row1.instanceManager.instances[0].tbcFirstNm);
Translate
Mayank_Gandhi
Mayank_GandhiAccepted solution
Employee
Sep 30, 2019 12:16 PM UTC

Try this:

alert(panel1393766227897.instanceManager.instances[panel1393766227897.instanceIndex].textbox_0.value);

Where  panel1393766227897 is your repeatable panel and textbox_0 is the textbox.

Thanks,

Mayank

Translate