Skip to Content

Locking items

Hi, is it possible to lock certain items so it is not possible to add them to some business partners sales orders?

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Posted on Oct 23, 2019 at 07:39 AM

    Dear Lisa Semple,

    please try this TN

    If (@object_type=N'17' and (@transaction_type IN ( 'A','U')))
    Begin
    IF EXISTS (SELECT '*'
    FROM ordr t0
    left outer join rdr1 t1 on t0."DocEntry"= t1."DocEntry"
    WHERE (t0."CardCode" ='cd001' or t1."ItemCode" ='itm001') AND t0."DocEntry"=@list_of_cols_val_tab_del)
    BEGIN
    select @error=15
    select @error_message='You are not authorised to add SO for This BP/Items'
    END
    END

    Danish

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 01, 2019 at 08:07 AM

    You need to customize that function with a UDT and Transaction Notification.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.