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
BedrockMission!

Learn more

View all

Sign in to view all badges

A repeating dynamic table with a sum total row showing or hiding fields

Raffe
Level 2
Level 2

Having a problem with a repeating dynamic table with a sum total row showing or hiding fields.

Total row calculates individual columns and if cell X >=1 hidden fields below appear and then the required info is filled in, and if cell X > 0 then hidden fields below do not appear.

The problem I am having, to get the hidden fields below to appear I am using the validate function. This works great excepting as soon as the number is 1 or more I get a popup saying the value I have entered is invalid. Now that in itself is not too much of a problem, but when I want to distribute the form this causes a problem with it and the form can’t be sent.


Any help in trying and solve this problem would be appreciated.

2 Replies
whyisthisme
Level 7
Level 7

try putting your code in the calculate event

Raffe
Level 2
Level 2

Have tried that but no joy.

I have included code for the events below.

form1.#subform[0].WS.Row4.Tn3::initialize - (JavaScript, client)

if (this.rawValue == null)

{

Injury1.presence = "hidden";

}

form1.#subform[0].WS.Row4.Tn3::calculate - (FormCalc, client)

// sum using FormCalc

$ = Sum(Row3[].n3[])+(RowFCE[].n3[])

form1.#subform[0].WS.Row4.Tn3::validate - (JavaScript, client)

if (this.rawValue >= 1)

{

Injury1.presence = "visible";

}

else if (this.rawValue < 1)

{

Injury1.presence = "hidden";

}