August 13, 201411 yr Newbies I have a Customer table with email address being the unique field If I enter a new customer then the system will tell me if I've entered a duplicate value in this field and offer to Revert the record, BUT I would like it to be a little more elegant... I'd like a script that, when entering a new Customer Record and on Exiting (completing) the Customer Email field: Checks if this value already exists in the database If Not then I can continue editing the current new record If so I would like the new record I'm entering to be reverted/deleted and to be automatically taken to the existing record I tried a script to do a Find on exiting the email field but... My dilemma seems to be that I have started to enter a new record and I have a script that fires when I exit the Customer email field The script then searches to see if that email address exists. The problem is that the script seems to save the new record at this point and so it either finds the record I've just entered or finds the existing record but ALSO saves the new record so now I have duplicates, grrrrr
August 13, 201411 yr There are a number of methods that are more elegant; which one to use depends on your workflow. Have a look at the attached file (FM 13 only). CheckAndSearch_eos.fmp12.zip
Create an account or sign in to comment