Data Entry Form Confirm Field Follow

James Anthony Williams

Hi all,

I'm looking for a way to have two fields the same and have one check against the other. The data would have to be entered twice and if one did not match the other it would cancel print job and return error. Any and all help would me much appreciated.


Pete Thane
Comment actions Permalink

Hi James,

Not sure how to create an error other than if we send a Print zero labels command.

For the code below I have linked the number of Copies on the File>Print screen to a NoofLabs field I have added onto the label (can be off to the side so it does not print). 

Field1Entry and Field2Entry are the names I have set for the 2 data sources to be compared.

NoofLabs is setup as VB>Event Controlled>OnIdenticalCopies script routine as follows


Value = 1

If Format.NamedSubStrings("Field2Entry").Value = Format.NamedSubStrings("Field1Entry").Value then
Value = 0
Else Value = 1

End if

Value = Value


This assumes the number of label required is always 1 but if it is different you can add that value in a new field and give that a name and then replace Else Value = 1 with 

Else Value = <the name of your field> (chosen by double clicking on it in the column in the right of the scripting window).


I hope this makes sense


Please sign in to leave a comment.