VendAccount in chequeDP class

Hi

I have an issue with vendor cheques my client is having two DBA’s, when we print the vendor cheques we print based on the vendor groups, the company name and company address is fetched from DBA based on Vendor group.

pastedimage1510858130740v1.png

The code is customized to bring the vendor account based on the recipient name, here the error comes if we have two vendors with same name it is picking the vendor which comes first sequence instead of second one. Since it is picking the first vendor it is taking the wrong dba and inserting the wrong logo and address of company. I want to know weather we have any other way to pull vendor account unique.

You can get the vendor account here, \Classes\CustVendCheque\initTmpChequePrintout