Why P0413M - Payment With Voucher Match takes Company 00000 Bank Account


VIP Member
I'm very much curious to know why "P0413M - Payment With Voucher Match" takes Company 00000 Bank Account.

Technical Details:
I have already defined AAI for PB for Company 22 as 22.110111.LOCA and doing payment for the same company.
But, it takes account from PB of Company 00000 ( which is 1.110111.ACC01 ).
When I checked the code of P0413M, there one BF B0400148 (Bank Account Set- DefaultPayablesBankAccount ) where company 00000 is passed, not the company of the current transaction ( here Co 22)

Is there any specific reason for this kind of 'hard coding' ?


VIP Member
I guess this is a bug !

Because if we apply security over companies it give error.

For example,
AAI item PB for Co 00000 is 3-111211-BANK10
AAI item PB for Co 22 is 22-111211-ZYZ01

If we want to restrict Co 22 to access only Co 22 records, once we apply the security it cannot fetch the account 3-111211-BANK10, and there will be hard error.