You need to sign in to do that
Don't have an account?
Milo6996
Prevent from using Duplication Pick list values
Hi All
I have been asked to amend our salesforce and am unsure of the best way to do it
I have an object call "Voucher" with a dropdown list called CODE of all the current voucher codes. Long story short, the voucher has a master lookup to an account.
I want it so when we create a new voucher code record the user will select from the picklist the code and that picklist value can only be used once. If it has been used against another account the use cant save the record
Thanks
Since there's no "unique" option for picklist fields, you will need to write an Apex trigger
Go thorugh this to write a trigger to prevent duplicates-
http://www.forcebrain.com/apex-trigger-preventing-duplicate-records-level-advanced/