Check Printing Template Using DLT103 Checks And 2 Window Envelope (Quickbooks )

Transitioned to ERPNEXT from QuickBooks Enterprise and wanted to use the stacks of checks already in hand. In case this can help anyone else in the same boat see below.

Add a custom field on the payment entry doc_type called Address Display type read only


Add another custom field called Supplier Account Number type data

Create a custom script in the Payment Entry doc_type

frappe.ui.form.on("Payment Entry", {
  party: function(frm) {
    frappe.call({
      method: "erpnext.accounts.party.get_party_details", //dotted path to server method,
      args: {
        'party': cur_frm.doc.party,
        'party_type': cur_frm.doc.party_type
      },
      callback: function(r) {
        // code snippet
        console.log("display address");
        if (r) {
          // $(frm.fields_dict['address_display'].wrapper).html(r.message.address_display);
          cur_frm.set_value("address_display", r.message.address_display);
          console.log(r);
        }
      }
    });
  }
});

Edit Cheque Printing Template with these settings:

Cheque Size:
A4
Starting position from top edge:
0.25
Cheque Width:
22
Cheque Height:
8.81
Is Account Payable:
Distance from top edge:
0
Distance from left edge:
0
Message to show:
.
Date Settings
Distance from top edge:
1.25
Starting location from left edge:
21.50
Distance from top edge:
2.50
Starting location from left edge:
4
Distance from top edge:
3.50
Starting location from left edge:
1.50
Width of amount in word:
15
Line spacing for amount in words:
0.50
Distance from top edge:
2.75
Starting location from left edge:
21.50
Distance from top edge:
7
Starting location from left edge:
4.50
Distance from top edge:
7.50
Starting location from left edge:
16.50

Then create a custom print format for the payment entry doc_type:

I used the html below, it also fetches the child table and prints the remittance in the center portion of the page below the actual check

<style>
	.print-format {
		padding: 0px;
	}
	@media screen {
		.print-format {
			padding: 0in;
		}
	}
</style>
<div style="position: relative; top:0.25cm">
	<div style="width:22.0cm;height:8.81cm;">
	
		<span style="top:.75cm; left:23cm;
			position: absolute;">
			<h4>{{ frappe.utils.formatdate(doc.reference_date) or '' }}</h4>
		</span>
		<span style="top:5.25cm;left:4cm;
			position: absolute;  min-width: 6cm;">
		<h4>{{doc.address_display or '' }}<br>Account# {{ doc.supplier_account_number or '' }}</h4>	
		</span>
		<span style="top:2.5cm;left: 4.0cm;
			position: absolute;  min-width: 6cm;">
		<h4>{{doc.party_name}}</h4>	
		</span>
		<span style="top:3.5cm; left:1.5cm;
			position: absolute; display: block; width: 15.0cm;
			line-height:0.5cm; word-wrap: break-word;">
			<h4>{{frappe.utils.money_in_words(doc.base_paid_amount or doc.base_received_amount)}}</h4>	
		</span>
		<span style="top:2.125cm;left: 23cm;
			position: absolute; min-width: 4cm;">
			<h4>{{doc.get_formatted("base_paid_amount") or doc.get_formatted("base_received_amount")}}</h4>
		</span>
		<span style="top:7.5cm;left: 16.5cm;
			position: absolute;  min-width: 6cm;">
		</span>
	</div>
</div>
<br>
<br><br><br><br><br>
 {%- if doc.references| count > 0 -%}
<h6>References</h6>
<table class="table table-bordered">
		<tbody>
			<tr>	
				<th>Type</th>
				<th>Name</th>
				<th>Vendor Invoice No.</th>
				<th>Original Amount</th>
				<th>Balance Due</th>
				<th>Payment</th>
			</tr>
			
			{%- for item in doc.references-%}
				<tr>
				<td> {{item.reference_doctype}}</td>
				<td> {{item.reference_name}}</td>
				<td> {{item.bill_no}}</td>
				<td> {{item.total_amount}}</td>
				<td> {{item.outstanding_amount}}</td>
				<td> {{item.allocated_amount}}</td>
				</tr>
			{%- endfor -%}
			
			
		</tbody>
	</table> 
{%endif%}

When the party is selected in the payment entry it will populate billing address and supplier account number. Select the print format just created and print the check. It will look odd on the print preview but will print correctly.

This worked for me but be sure to test. This will also allow using the 2 window envelope for addresses
Envelope:
(92663 a.k.a. 1238657, RN DWE009SS Double Window Security Tinted Check Envelope, Self Seal)

Hope this helps