Avatar

Correct answer by
Level 7

Here is some code in Formcalc which will work for what you want. Put it in the exit event for the textfield.

In this example the page is called myPage and the textField is called TextField1. Rename them as you need.

var indexCount = 0

var thisIndex = $.parent.index

while (indexCount < thisIndex) do

if (myPage[indexCount].TextField1 == myPage[thisIndex].TextField1) then

xfa.host.messageBox("You have already used that number")

$ = ""

endif

indexCount = indexCount + 1

endwhile

View solution in original post