August 11, 201015 yr Having a brain fade here, need a calculation to check a field called "Trips" so that no Trip Name is the same. I no I can use the validate option in the field options but it's cryptic message is not much good to a user. I like to attach the script to a Script Tigger. Many Thanks
August 11, 201015 yr but it's cryptic message is not much good to a user. Many Thanks FYI, you can check the box at the bottom of the validate window and write your own error message, its much easier to use the built in features if all you need is a custom message.
August 11, 201015 yr You could use a self-join relationship matching on Trip Name and count the related records. However, relying on a script trigger alone to ensure data integrity is not the best practice. In version 11 you can have the best of both worlds by triggering the script OnObjectValidate.
August 11, 201015 yr Author Thanks for the quick replys, I know about the Message box, but I want to script it after the duplicate is typed in, such as: Field "TripName" if a user types in the name of a trip that already exists, then Tabs out of the field, I want to alert them to the duplicate name and send them back to the field to change it. What I'm after is a script that see's the duplicate and alerts them, what calculations do I need in the script? I've tried "Self" and a few others but no luck.
August 11, 201015 yr You cannot calculate if the current record contains a value that exists in another record without a relationship. Without a relationship, you would need to perform a find.
August 14, 201015 yr Author Sorry about the delay in getting back, but finally sorted it out. Many Thanks to all.
Create an account or sign in to comment