Additional unique attribute

The 1C:Enterprise developers forum

#1
People who like this:0Yes/0No
Active user
Rating: 6
Joined: Sep 16, 2011
Company: TLG Integration

Hello!

I would like to make one of my custom attributes being unique. In addition to Code. But can't find any properties to set it unique.
Is there a way to do so?

 
#2
People who like this:0Yes/0No
Timofey Bugaevsky
Guest

Joined:
Company:

You need to check it in BeforeWrite event in your catalog's Object Module using a query and if an item with the same attribute value is found you should set Cancel parameter of the event handler to True and return.

 
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)
Be the first to know tips & tricks on business application development!

A confirmation e-mail has been sent to the e-mail address you provided .

Click the link in the e-mail to confirm and activate the subscription.