Why does the system show error ‘Cctr Code is Blank’ while saving Payment against voucher?

Cause:
In Payment against voucher, the system will not allow you to confirm payment against voucher if cctr code is blank or invalid. System will show the error message ‘VTNULCCTR’, ‘ Cctr Code is Blank’ and ‘cctr code cannot be blank’. Sometimes, In cctr_code, spaces are entered then the system shows ‘VMCCTRMT’, ‘Invalid Cctr Code !’ and ‘Entered cctr code not defined in costctr master’.
Suggestions:
User should ensure that cctr code is defined in costctr master. If space is entered in master then CCTR_code_Ap should be updated in Misc payables, customer and supplier masters. Then the user should ensure that under the accounting group, Cost center code is selected and is populated. Users can then finish the record.