<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[FrontAccounting forum — How to design invoice form]]></title>
		<link>https://frontaccounting.com/punbb/viewtopic.php?id=1676</link>
		<atom:link href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=1676&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in How to design invoice form.]]></description>
		<lastBuildDate>Sun, 07 Aug 2016 12:49:23 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=25979#p25979</link>
			<description><![CDATA[<p>You&#039;re most welcome and in your turn you too can help other newbies getting their feet wet in FA.</p><p>Since you have managed to make and test such a version of the <strong>header2.inc</strong>, you can submit it in 2 parts to the project - one having just the lines to make pre-printed stationery, and another for use with such pre-printed stationery.</p>]]></description>
			<author><![CDATA[null@example.com (apmuthu)]]></author>
			<pubDate>Sun, 07 Aug 2016 12:49:23 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=25979#p25979</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=25978#p25978</link>
			<description><![CDATA[<p>Solved, but how can I forget to say <strong>T H A N K&nbsp; &nbsp;YOU /&nbsp; Salute</strong> bro.<br /></p><div class="quotebox"><cite>apmuthu wrote:</cite><blockquote><p>Most, if not all lines are in the <strong>reporting/includes/header2.inc</strong> file. Try commenting out sets of lines at a time and see what disappears in the resulting invoice.... Also see what is necessary to manage the position ($x, $y co-ordinates) of the subsequent printing....</p></blockquote></div>]]></description>
			<author><![CDATA[null@example.com (sarthor)]]></author>
			<pubDate>Sat, 06 Aug 2016 16:24:27 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=25978#p25978</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=25976#p25976</link>
			<description><![CDATA[<p>Most, if not all lines are in the <strong>reporting/includes/header2.inc</strong> file. Try commenting out sets of lines at a time and see what disappears in the resulting invoice.... Also see what is necessary to manage the position ($x, $y co-ordinates) of the subsequent printing....</p>]]></description>
			<author><![CDATA[null@example.com (apmuthu)]]></author>
			<pubDate>Sat, 06 Aug 2016 13:31:54 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=25976#p25976</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=25974#p25974</link>
			<description><![CDATA[<div class="quotebox"><cite>bibin141 wrote:</cite><blockquote><p>Hello Guys,<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;I am a intermediate php programmer, i have created a INVOICE&nbsp; form design which suitable for indian users,</p><p>My form contains S.NO , Item Des ,&nbsp; Qty , Rate, Gross , Dis% , DisAmt , Vat% , VatAmt, Total,</p><p>I designed this form for my business.If u are interested in this design then go and edit reporting/rep107.php.</p><p>Note : Better take a backup of this file before altering it.</p><p>Here is the complete coding for my design</p><p>&lt;?php<br />/**********************************************************************<br />&nbsp; &nbsp; Copyright (C) FrontAccounting, LLC.<br />&nbsp; &nbsp; Released under the terms of the GNU General Public License, GPL, <br />&nbsp; &nbsp; as published by the Free Software Foundation, either version 3 <br />&nbsp; &nbsp; of the License, or (at your option) any later version.<br />&nbsp; &nbsp; This program is distributed in the hope that it will be useful,<br />&nbsp; &nbsp; but WITHOUT ANY WARRANTY; without even the implied warranty of<br />&nbsp; &nbsp; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.&nbsp; <br />&nbsp; &nbsp; See the License here &lt;http://www.gnu.org/licenses/gpl-3.0.html&gt;.<br />***********************************************************************/<br />$page_security = $_POST[&#039;PARAM_0&#039;] == $_POST[&#039;PARAM_1&#039;] ?<br />&nbsp; &nbsp; &#039;SA_SALESTRANSVIEW&#039; : &#039;SA_SALESBULKREP&#039;;<br />// ----------------------------------------------------------------</p><br /><p>?&gt;</p></blockquote></div><p>HI, hope you doing great joe,<br />What if I want to line in my invoice? I want to print paper from printing press, and my frontaccounting only write text there, becuase I am using dot matrix printer and that take long time for printing lines, especially that vertical lines, So please help me that how can I remove all the lines from invoice, that will be better if you can paste that complete code here of that file, I am not expert , but I can go and copy paste things in /reporting/includes/ directory. Thanks in advance, and will wait for your reply. Thanks again bro.</p>]]></description>
			<author><![CDATA[null@example.com (sarthor)]]></author>
			<pubDate>Sat, 06 Aug 2016 09:25:33 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=25974#p25974</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=18745#p18745</link>
			<description><![CDATA[<p>I found the solution :-) Even though I started Kate with kdesu variable, the changes was not saved. I used Nano and I could do the adjustment.&nbsp; $this-&gt;row = $this-&gt;pageHeight - $this-&gt;topMargin - 3 * $this-&gt;lineHeight;</p>]]></description>
			<author><![CDATA[null@example.com (jel)]]></author>
			<pubDate>Fri, 13 Dec 2013 15:25:13 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=18745#p18745</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=18744#p18744</link>
			<description><![CDATA[<p>It is the first row after the comments.<br />&nbsp; &nbsp; &nbsp; &nbsp; $this-&gt;row = $this-&gt;pageHeight - $this-&gt;topMargin - 45;</p><p>&nbsp; &nbsp; &nbsp; &nbsp; $upper = $this-&gt;row - 2 * $this-&gt;lineHeight;<br />&nbsp; &nbsp; &nbsp; &nbsp; $lower = $this-&gt;bottomMargin + 8 * $this-&gt;lineHeight;<br />&nbsp; &nbsp; &nbsp; &nbsp; $iline1 = $upper - 7.5 * $this-&gt;lineHeight;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; etc.</p><p>Jan-Eric</p>]]></description>
			<author><![CDATA[null@example.com (jel)]]></author>
			<pubDate>Fri, 13 Dec 2013 15:07:13 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=18744#p18744</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=18743#p18743</link>
			<description><![CDATA[<p>Well, I am not at the source computer right now. Please have a look into the code, that the row&nbsp; is not set later.</p><p>Joe</p>]]></description>
			<author><![CDATA[null@example.com (joe)]]></author>
			<pubDate>Fri, 13 Dec 2013 14:58:37 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=18743#p18743</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=18742#p18742</link>
			<description><![CDATA[<p>No doesn&#039;t work, I haved tried with -45 and nothing changes</p><p>Jan-Eric</p>]]></description>
			<author><![CDATA[null@example.com (jel)]]></author>
			<pubDate>Fri, 13 Dec 2013 14:39:25 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=18742#p18742</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=18740#p18740</link>
			<description><![CDATA[<p>The values decrease from top to bottom. So I guess you should use, - 18, instead of + 18.</p><p>Joe</p>]]></description>
			<author><![CDATA[null@example.com (joe)]]></author>
			<pubDate>Fri, 13 Dec 2013 12:46:15 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=18740#p18740</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=18739#p18739</link>
			<description><![CDATA[<p>I have tried to increase the top margin in file header2inc: $this-&gt;row = $this-&gt;pageHeight - $this-&gt;topMargin;<br />to this value: $this-&gt;row = $this-&gt;pageHeight - $this-&gt;topMargin + 18;</p><p>Nothing changes.<br />How can I increase top margin?</p><p>Jan-Eric</p>]]></description>
			<author><![CDATA[null@example.com (jel)]]></author>
			<pubDate>Fri, 13 Dec 2013 11:53:20 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=18739#p18739</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=17010#p17010</link>
			<description><![CDATA[<p>Hello Guys,<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;I am a intermediate php programmer, i have created a INVOICE&nbsp; form design which suitable for indian users,</p><p>My form contains S.NO , Item Des ,&nbsp; Qty , Rate, Gross , Dis% , DisAmt , Vat% , VatAmt, Total,</p><p>I designed this form for my business.If u are interested in this design then go and edit reporting/rep107.php.</p><p>Note : Better take a backup of this file before altering it.</p><p>Here is the complete coding for my design</p><p>&lt;?php<br />/**********************************************************************<br />&nbsp; &nbsp; Copyright (C) FrontAccounting, LLC.<br />&nbsp; &nbsp; Released under the terms of the GNU General Public License, GPL, <br />&nbsp; &nbsp; as published by the Free Software Foundation, either version 3 <br />&nbsp; &nbsp; of the License, or (at your option) any later version.<br />&nbsp; &nbsp; This program is distributed in the hope that it will be useful,<br />&nbsp; &nbsp; but WITHOUT ANY WARRANTY; without even the implied warranty of<br />&nbsp; &nbsp; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.&nbsp; <br />&nbsp; &nbsp; See the License here &lt;http://www.gnu.org/licenses/gpl-3.0.html&gt;.<br />***********************************************************************/<br />$page_security = $_POST[&#039;PARAM_0&#039;] == $_POST[&#039;PARAM_1&#039;] ?<br />&nbsp; &nbsp; &#039;SA_SALESTRANSVIEW&#039; : &#039;SA_SALESBULKREP&#039;;<br />// ----------------------------------------------------------------<br />// $ Revision:&nbsp; &nbsp; 2.0 $<br />// Creator:&nbsp; &nbsp; Joe Hunt<br />// date_:&nbsp; &nbsp; 2005-05-19<br />// Title:&nbsp; &nbsp; Print Invoices<br />// ----------------------------------------------------------------<br />$path_to_root=&quot;..&quot;;</p><p>include_once($path_to_root . &quot;/includes/session.inc&quot;);<br />include_once($path_to_root . &quot;/includes/date_functions.inc&quot;);<br />include_once($path_to_root . &quot;/includes/data_checks.inc&quot;);<br />include_once($path_to_root . &quot;/sales/includes/sales_db.inc&quot;);</p><p>//----------------------------------------------------------------------------------------------------</p><p>print_invoices();</p><p>//----------------------------------------------------------------------------------------------------</p><p>function print_invoices()<br />{<br />&nbsp; &nbsp; global $path_to_root, $alternative_tax_include_on_docs, $suppress_tax_rates, $no_zero_lines_amount;<br />&nbsp; &nbsp; <br />&nbsp; &nbsp; include_once($path_to_root . &quot;/reporting/includes/pdf_report.inc&quot;);</p><p>&nbsp; &nbsp; $from = $_POST[&#039;PARAM_0&#039;];<br />&nbsp; &nbsp; $to = $_POST[&#039;PARAM_1&#039;];<br />&nbsp; &nbsp; $currency = $_POST[&#039;PARAM_2&#039;];<br />&nbsp; &nbsp; $email = $_POST[&#039;PARAM_3&#039;];<br />&nbsp; &nbsp; $pay_service = $_POST[&#039;PARAM_4&#039;];<br />&nbsp; &nbsp; $comments = $_POST[&#039;PARAM_5&#039;];<br />&nbsp; &nbsp; $customer = $_POST[&#039;PARAM_6&#039;];<br />&nbsp; &nbsp; $orientation = $_POST[&#039;PARAM_7&#039;];</p><p>&nbsp; &nbsp; if (!$from || !$to) return;</p><p>&nbsp; &nbsp; $orientation = ($orientation ? &#039;L&#039; : &#039;P&#039;);<br />&nbsp; &nbsp; $dec = user_price_dec();</p><p> &nbsp; &nbsp; $fno = explode(&quot;-&quot;, $from);<br />&nbsp; &nbsp; $tno = explode(&quot;-&quot;, $to);<br />&nbsp; &nbsp; $from = min($fno[0], $tno[0]);<br />&nbsp; &nbsp; $to = max($fno[0], $tno[0]);</p><p>&nbsp; &nbsp; //Modify this valus to increase or decrease column size<br />&nbsp; &nbsp; $cols = array(10, 40, 170, 200, 250,300, 340, 380, 420, 450, 0);&nbsp; </p><p>&nbsp; &nbsp; // $headers in doctext.inc <br />&nbsp; &nbsp; $aligns = array(&#039;left&#039;,&nbsp; &nbsp; &#039;left&#039;,&nbsp; &nbsp; &#039;left&#039;,&nbsp; &nbsp; &#039;left&#039;, &#039;left&#039;, &#039;left&#039;, &#039;left&#039;, &#039;left&#039;, &#039;left&#039;, &#039;right&#039;);</p><p>&nbsp; &nbsp; $params = array(&#039;comments&#039; =&gt; $comments);</p><p>&nbsp; &nbsp; $cur = get_company_Pref(&#039;curr_default&#039;);</p><p>&nbsp; &nbsp; if ($email == 0)<br />&nbsp; &nbsp; &nbsp; &nbsp; $rep = new FrontReport(_(&#039;INVOICE&#039;), &quot;InvoiceBulk&quot;, user_pagesize(), 9, $orientation);<br />&nbsp; &nbsp; if ($orientation == &#039;L&#039;)<br />&nbsp; &nbsp; &nbsp; &nbsp; recalculate_cols($cols);<br />&nbsp; &nbsp; for ($i = $from; $i &lt;= $to; $i++)<br />&nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (!exists_customer_trans(ST_SALESINVOICE, $i))<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; continue;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $sign = 1;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $myrow = get_customer_trans($i, ST_SALESINVOICE);</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if($customer &amp;&amp; $myrow[&#039;debtor_no&#039;] != $customer) {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; continue;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $baccount = get_default_bank_account($myrow[&#039;curr_code&#039;]);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $params[&#039;bankaccount&#039;] = $baccount[&#039;id&#039;];</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $branch = get_branch($myrow[&quot;branch_code&quot;]);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $sales_order = get_sales_order_header($myrow[&quot;order_&quot;], ST_SALESORDER);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($email == 1)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep = new FrontReport(&quot;&quot;, &quot;&quot;, user_pagesize(), 9, $orientation);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;title = _(&#039;INVOICE&#039;);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;filename = &quot;Invoice&quot; . $myrow[&#039;reference&#039;] . &quot;.pdf&quot;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }&nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;SetHeaderType(&#039;Header2&#039;);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;currency = $cur;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;Font();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;Info($params, $cols, null, $aligns);</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $contacts = get_branch_contacts($branch[&#039;branch_code&#039;], &#039;invoice&#039;, $branch[&#039;debtor_no&#039;], true);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $baccount[&#039;payment_service&#039;] = $pay_service;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;SetCommonData($myrow, $branch, $sales_order, $baccount, ST_SALESINVOICE, $contacts);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewPage();<br />&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $result = get_customer_trans_details(ST_SALESINVOICE, $i);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $SubTotal = 0;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // This variable $n used for SNO calculation.<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $no=1;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; while ($myrow2=db_fetch($result))<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($myrow2[&quot;quantity&quot;] == 0)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; continue;</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $Net = round2($sign * ((1 - $myrow2[&quot;discount_percent&quot;]) * $myrow2[&quot;unit_price&quot;] * $myrow2[&quot;quantity&quot;]),<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp; user_price_dec());<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $SubTotal += $Net;<br />&nbsp; &nbsp;&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $DispTax = number_format2($myrow2[&quot;unit_tax&quot;] * 100 / $myrow2[&quot;unit_price&quot;],user_percent_dec()) . &quot;%&quot;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $Dispgross = $myrow2[&quot;quantity&quot;] * $myrow2[&quot;unit_price&quot;];<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $Dispda = $myrow2[&quot;discount_percent&quot;] * $myrow2[&quot;unit_price&quot;] * $myrow2[&quot;quantity&quot;];<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $DisplayPrice = number_format2($myrow2[&quot;unit_price&quot;],$dec);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp;&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; $DisplayQty = number_format2($sign*$myrow2[&quot;quantity&quot;],get_qty_dec($myrow2[&#039;stock_id&#039;]));&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp;&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; $DisplayNet = number_format2($Net,$dec);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // str_replace(&quot;,&quot;, &quot;&quot;, $_POST[&#039;price&#039;]);&nbsp; for string removal<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; $net1 = str_replace(&quot;,&quot;, &quot;&quot;, $DisplayNet);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $Dispvm = number_format2($net1 * $DispTax / 100 ,$dec);&nbsp; // To display vat Amount<br />&nbsp; &nbsp;&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($myrow2[&quot;discount_percent&quot;]==0)<br />&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $DisplayDiscount =&quot;&quot;;<br />&nbsp; &nbsp;&nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; else<br />&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $DisplayDiscount = number_format2($myrow2[&quot;discount_percent&quot;]*100,user_percent_dec()) . &quot;%&quot;;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; //$rep-&gt;TextCol(0, 1,&nbsp; &nbsp; $myrow2[&#039;stock_id&#039;], -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; //&nbsp; $rep-&gt;TextCol(0, 1,&nbsp; &nbsp; $myrow2[&#039;StockDescription&#039;], -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;// New Altered coding<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; $rep-&gt;TextCol(0, 1,&nbsp; &nbsp; $no, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $oldrow = $rep-&gt;row;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextColLines(1, 2, $myrow2[&#039;StockDescription&#039;], -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $newrow = $rep-&gt;row;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;row = $oldrow;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($Net != 0.0 || !is_service($myrow2[&#039;mb_flag&#039;]) || !isset($no_zero_lines_amount) || $no_zero_lines_amount == 0)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(2, 3,&nbsp; &nbsp; $DisplayQty, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(3, 4,&nbsp; &nbsp; $DisplayPrice, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(4, 5,&nbsp; &nbsp; $Dispgross, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(5, 6,&nbsp; &nbsp; $DisplayDiscount, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(6, 7,&nbsp; &nbsp; $Dispda, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(7, 8,&nbsp; &nbsp; $DispTax, -2); <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(8, 9,&nbsp; &nbsp; $Dispvm, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(9, 10,$DisplayNet, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $no++;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }&nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;row = $newrow;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; //$rep-&gt;NewLine(1);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($rep-&gt;row &lt; $rep-&gt;bottomMargin + (15 * $rep-&gt;lineHeight))<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewPage();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $memo = get_comments_string(ST_SALESINVOICE, $i);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($memo != &quot;&quot;)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewLine();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextColLines(1, 5, $memo, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }</p><p>&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $DisplaySubTot = number_format2($SubTotal,$dec);<br />&nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $DisplayFreight = number_format2($sign*$myrow[&quot;ov_freight&quot;],$dec);</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;row = $rep-&gt;bottomMargin + (15 * $rep-&gt;lineHeight);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $doctype = ST_SALESINVOICE;</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(6, 9, _(&quot;Sub-total&quot;), -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(9, 10,&nbsp; &nbsp; $DisplaySubTot, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewLine();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(6, 9, _(&quot;Shipping&quot;), -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(9, 10,&nbsp; &nbsp; $DisplayFreight, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewLine();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $tax_items = get_trans_tax_details(ST_SALESINVOICE, $i);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $first = true;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; while ($tax_item = db_fetch($tax_items))<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($tax_item[&#039;amount&#039;] == 0)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; continue;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $DisplayTax = number_format2($sign*$tax_item[&#039;amount&#039;], $dec);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (isset($suppress_tax_rates) &amp;&amp; $suppress_tax_rates == 1)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $tax_type_name = $tax_item[&#039;tax_type_name&#039;];<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; else<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $tax_type_name = $tax_item[&#039;tax_type_name&#039;].&quot; (&quot;.$tax_item[&#039;rate&#039;].&quot;%) &quot;;</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($tax_item[&#039;included_in_price&#039;])<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (isset($alternative_tax_include_on_docs) &amp;&amp; $alternative_tax_include_on_docs == 1)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($first)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(6, 9, _(&quot;Total Tax Excluded&quot;), -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(9, 10,&nbsp; &nbsp; number_format2($sign*$tax_item[&#039;net_amount&#039;], $dec), -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewLine();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(6, 9, $tax_type_name, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(9, 10,&nbsp; &nbsp; $DisplayTax, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $first = false;<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; else<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(3, 7, _(&quot;Included&quot;) . &quot; &quot; . $tax_type_name . _(&quot;Amount&quot;) . &quot;: &quot; . $DisplayTax, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; else<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(6, 9, $tax_type_name, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(9, 10,&nbsp; &nbsp; $DisplayTax, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewLine();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }</p><p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewLine();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $DisplayTotal = number_format2($sign*($myrow[&quot;ov_freight&quot;] + $myrow[&quot;ov_gst&quot;] +<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $myrow[&quot;ov_amount&quot;]+$myrow[&quot;ov_freight_tax&quot;]),$dec);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;Font(&#039;bold&#039;);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(6, 9, _(&quot;TOTAL INVOICE&quot;), - 2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(9, 10, $DisplayTotal, -2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $words = price_in_words($myrow[&#039;Total&#039;], ST_SALESINVOICE);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($words != &quot;&quot;)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;NewLine(1);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;TextCol(1, 7, $myrow[&#039;curr_code&#039;] . &quot;: &quot; . $words, - 2);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;Font();<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if ($email == 1)<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;End($email);<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; }<br />&nbsp; &nbsp; if ($email == 0)<br />&nbsp; &nbsp; &nbsp; &nbsp; $rep-&gt;End();<br />}</p><p>?&gt;</p>]]></description>
			<author><![CDATA[null@example.com (bibin141)]]></author>
			<pubDate>Wed, 10 Jul 2013 08:48:10 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=17010#p17010</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=16787#p16787</link>
			<description><![CDATA[<p>GST number is displayed above Charge To details in horizontal table under &#039;Your VAT no.&#039; title.<br />Janusz</p>]]></description>
			<author><![CDATA[null@example.com (itronics)]]></author>
			<pubDate>Tue, 04 Jun 2013 13:14:39 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=16787#p16787</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=16760#p16760</link>
			<description><![CDATA[<p>Hi Joe,</p><p>It is a government requirement to place the GST Number of the Customer in the Invoice format.<br />Please help how do I insert the information right under the &quot;Charge To&quot; details.</p>]]></description>
			<author><![CDATA[null@example.com (RyanPichay)]]></author>
			<pubDate>Thu, 30 May 2013 07:45:12 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=16760#p16760</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=7855#p7855</link>
			<description><![CDATA[<div class="quotebox"><cite>joe wrote:</cite><blockquote><p>The NewLine produces 12 cr/nl.<br />The TextCol uses the column definition for 4 and 7/5. If you want to print exactly you can use other routines in /reporting/includes/pdf_report.inc..</p><p>Normally we don&#039;t have resources to help with design of reports, so you are on your own here. Maybe some from the community can help you.</p><p>/Joe</p></blockquote></div><p>thank you joe. i am a noob in programming, so i am trying to learn and understand and hopefully contribute back to the community</p>]]></description>
			<author><![CDATA[null@example.com (spacewalker)]]></author>
			<pubDate>Wed, 29 Dec 2010 16:08:53 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=7855#p7855</guid>
		</item>
		<item>
			<title><![CDATA[Re: How to design invoice form]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=7851#p7851</link>
			<description><![CDATA[<p>The NewLine produces 12 cr/nl.<br />The TextCol uses the column definition for 4 and 7/5. If you want to print exactly you can use other routines in /reporting/includes/pdf_report.inc..</p><p>Normally we don&#039;t have resources to help with design of reports, so you are on your own here. Maybe some from the community can help you.</p><p>/Joe</p>]]></description>
			<author><![CDATA[null@example.com (joe)]]></author>
			<pubDate>Wed, 29 Dec 2010 08:33:08 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=7851#p7851</guid>
		</item>
	</channel>
</rss>
