cancel
Showing results for 
Search instead for 
Did you mean: 

Invoice without Base Document

Former Member
0 Kudos

Hi There,

Does anyone know if it is possible to write a stored proc (transaction notification) to block a user from creating an AR Invoice if it doesnt have a base document(quote or order)? And if so, is there anyone that can assist in writing something like this?

Regards,

Wynand.

Accepted Solutions (1)

Accepted Solutions (1)

former_member204969
Active Contributor
0 Kudos

Try this code in SBO_SP_TransactionNotification stored procedure :

IF @transaction_type = 'A' AND @object_type = '13'  
BEGIN
if exists(Select ItemCode from [dbo].[INV1] T0
 Where T0.BaseEntry IS NULL 
   AND T0.DocEntry=@list_of_cols_val_tab_del)
begin
	SELECT @error = 1, @error_message = 'Invoice without Base Document !'
end

END

Answers (0)