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

Help with script

Avatar

Level 7

I have in a repeating table rows a DDList and a TextField1(Type:Read Only) with default text:MANTATORY.

For the DDList I have about 20 items listed and one of them the Course A is Optional.

On change event I have the following script:

var vConversion = "MANTATORY";

switch

(xfa.event.newText)

{

case "CourseA":

vConversion

= "OPTIONAL";

break;

}

form1.PageA.Sub_C.Table1.TextField1.rawValue = vConversion;

When I add  a instance for the table and from the DDList I have to select CourseA

the textField1 for the Instance 2 does not change to OPTIONAL(Remains MANTATORY)!

It will change the instance 1 to OPTIONAL form MANTATORY!

How I can solve this issue?

Thank you

0 Replies

Avatar

Level 10

Hi,

you need to reference the instance of your table row to update the correct field.

Sorry, could not determine what is the row in your syntax (Sub_C or Table1)

Try this if Sub_C is the row:

else

Avatar

Level 7

here is the syntax for the TextField1:

form1.PageA.Sub_C.Table1.Item.TextField1

Thanks Radzmar

Avatar

Level 7

Thanks Radzmar for all your help...Thank you

xfa.resolveNode("form1.PageA.Sub_C.Table1.Item.ReusablesRemarksName["

+ this.index + "]").rawValue = vConversion;