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

SOLVED

Triggering a JavaScript from a field

Avatar

Level 5

Hello!

I created a form where there are three fields, VALUE1, VALUE2 and TOTAL.

Using FormCalc, I calculate TOTAL this way:

form1.#subform[0].total::calculate - (FormCalc, client)
valor1 + valor2

It works....

Now, I'd like to do the very same thing using JavaScript, but it doesn't work. Why?

Can I have both FormCalc and JavaScript working in the same form?

Thank you for any hints!

Marcos

1 Accepted Solution

Avatar

Correct answer by
Level 10

Yes you can have Javascript and FormCalc on the same form but not in the same event.

Your formula in javascript woudl be:

this.rawValue = valor1.rawValue + valor2.rawValue

Paul

View solution in original post

0 Replies

Avatar

Correct answer by
Level 10

Yes you can have Javascript and FormCalc on the same form but not in the same event.

Your formula in javascript woudl be:

this.rawValue = valor1.rawValue + valor2.rawValue

Paul