Skip to Content
avatar image
Former Member

Need to block approval if a Reason, Remarks is not mentioned

Dear Experts

we had Approval Process for Delivery note Return, i need to the user to make it mandatory and force them to insert the Reason of Return in Approval ,

can an one give me the SPT for the same

Regards

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Apr 24, 2017 at 12:13 AM

    Hi Shahan,

    You can do this with the object type 122. A sample for your scenario.

    IF @object_type = '122' AND @transaction_type IN ('A')
    BEGIN
    	IF (SELECT COUNT(*) FROM OWDD WHERE WddCode = @list_of_cols_val_tab_del AND ISNULL(Remarks, '') = '') > 0
    	BEGIN
    		SET @error = -1
    		SET @error_message = N'It is necessary provide some remarks for approval procedure'
    	END
    END
    

    Hope it helps.

    Kind Regards,

    Diego Lother

    Add comment
    10|10000 characters needed characters exceeded