1\documentclass{scrartcl} 2\usepackage[latin1]{inputenc} 3\usepackage{tabularx} 4\usepackage[letterpaper,top=2cm,bottom=-3cm,left=1.1cm,right=1.5cm]{geometry} 5\usepackage{graphicx} 6\setlength{\parindent}{0pt} 7 8\begin{document} 9 10\pagestyle{myheadings} 11\thispagestyle{empty} 12 13\fontfamily{cmss}\fontsize{10pt}{12pt}\selectfont 14 15<%include letterhead.tex%> 16 17\centerline{\textbf{A P} \hspace{0.3cm} \textbf{T R A N S A C T I O N}} 18 19\vspace*{0.5cm} 20 21\parbox[t]{.5\textwidth}{ 22<%name%> 23 24<%address1%> 25 26<%address2%> 27 28<%city%> 29<%if state> 30\hspace{-0.1cm}, <%state%> 31<%end state%> <%zipcode%> 32 33<%country%> 34 35\vspace{0.3cm} 36 37<%if contact%> 38<%contact%> 39\vspace{0.2cm} 40<%end contact%> 41 42<%if vendorphone%> 43Tel: <%vendorphone%> 44<%end vendorphone%> 45 46<%if vendorfax%> 47Fax: <%vendorfax%> 48<%end vendorfax%> 49 50<%email%> 51 52<%if vendortaxnumber%> 53Tax Number: <%vendortaxnumber%> 54<%end vendortaxnumber%> 55} 56\hfill 57\begin{tabular}[t]{ll} 58 \textbf{Invoice \#} & <%invnumber%> \\ 59 \textbf{Date} & <%invdate%> \\ 60 \textbf{Due} & <%duedate%> \\ 61 <%if ponumber%> 62 \textbf{PO \#} & <%ponumber%> \\ 63 <%end ponumber%> 64 <%if ordnumber%> 65 \textbf{Order \#} & <%ordnumber%> \\ 66 <%end ordnumber%> 67 \textbf{Employee} & <%employee%> \\ 68\end{tabular} 69 70\vspace{1cm} 71 72\begin{tabularx}{\textwidth}[t]{@{}llrX@{\hspace{1cm}}l@{}} 73<%foreach amount%> 74 <%accno%> & <%account%> & <%amount%> & <%description%> & <%projectnumber%> \\ 75<%end amount%> 76 77 \multicolumn{2}{r}{\textbf{Subtotal}} & <%subtotal%> & \\ 78<%foreach tax%> 79 \multicolumn{2}{r}{\textbf{<%taxdescription%> @ <%taxrate%> \%}} & <%tax%> & \\ 80<%end tax%> 81 82 \multicolumn{2}{r}{\textbf{Total}} & <%invtotal%> & \\ 83 84\end{tabularx} 85 86\vspace{0.3cm} 87 88<%text_amount%> ***** <%decimal%>/100 <%currency%> 89 90<%if notes%> 91\vspace{0.3cm} 92<%notes%> 93<%end notes%> 94 95\vspace{0.3cm} 96 97<%if paid_1%> 98\begin{tabular}{@{}llllr@{}} 99 \multicolumn{5}{c}{\textbf{Payments}} \\ 100 \hline 101 \textbf{Date} & & \textbf{Source} & \textbf{Memo} & \textbf{Amount} \\ 102<%end paid_1%> 103<%foreach payment%> 104 <%paymentdate%> & <%paymentaccount%> & <%paymentsource%> & <%paymentmemo%> & <%payment%> \\ 105<%end payment%> 106<%if paid_1%> 107\end{tabular} 108<%end paid_1%> 109 110\end{document} 111 112