on 09-20-2011 4:08 PM
Dear All,
Our client would like to know how to make project field mandatory (Purchase order >> Line >> Project field).
Do we need a UDV? Thanks in advance.
Regards,
Yuka
In version 8.81 there is general setting making mandarory the project code (for accounts set for cost acounting) under General Settings / Cost Accountin tab.
For earlier versions or specificaly only for purchase order lines you can use this code:
If @object_type = '22'
begin
if exists(select 'A' from opor T0 inner join por1 T1 on T0.DocEntry = T1.DocEntry
where T0.ObjType = '22' and isnull(T1.Project,'') = ''
and T0.DocEntry = @list_of_cols_val_tab_del)
begin
set @error = 1
set @error_message = 'Project is missing PO'
end
end
Insert the above code into your SBO_SP_TransactionNotification stored procedure after the line
-- ADD YOUR CODE HERE
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
107 | |
12 | |
11 | |
6 | |
5 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.