If/then/else using a greater than option


i have the  need script in form calculate between 2 'fields' - @ both fields, , enter 1 lessor value. have written such:

 

var = this.getfield("text10")

var b = this.getfield("text8")

if (a.value < b.value) {

event.value = getfield("text8")}

else {event.value = getfield("text10")

}

 

i'm not getting errors, blank field...

 

(and yes, text8 , text10 fields have data) :-)

 

i'm novice regarding javascript, appreciated.

 

thanks!

 

jill

 

 

- using adobe acrobat 9 pro on mac lion

use this:

 

var = number(this.getfield("text10").value);

var b = number(this.getfield("text8").value);

event.value = math.min(a,b);



More discussions in JavaScript


adobe

Comments

Popular posts from this blog

How to set the order of FAQs instead of alphabetical

Thread: Get UK Keyboard working

how do I change the e-mail address for my merchant account