﻿<?xml version="1.0" encoding="utf-8"?>
<inherited BaseReport="..\Base.frx" ScriptLanguage="CSharp" DoublePass="true" ReportInfo.Created="05/15/2013 14:45:40" ReportInfo.Modified="03/31/2015 12:20:59" ReportInfo.CreatorVersion="1.6.57.0">
  <ScriptText>using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Windows.Forms;
using System.Drawing;
using System.Data;
using FastReport;
using FastReport.Data;
using FastReport.Dialog;
using FastReport.Barcode;
using FastReport.Table;
using FastReport.Utils;

namespace FastReport
{
  public class ReportScript
  {
         

    private void Form1_Shown(object sender, EventArgs e)
    {
      dtpFromDate.Text = System.DateTime.Now.ToString(&quot;d MMMM yyy&quot;);
      dtpToDate.Text = System.DateTime.Now.ToString(&quot;d MMMM yyy&quot;);
      
      cboClientName.Items.Insert(0, &quot;All&quot;);
      cboClientName.Text = &quot;All&quot;;
      cboOrderBy.Text = cboOrderBy.Items[0].ToString();
    }

    
    private void btnOk_Click(object sender, EventArgs e)
    {
      Report.SetParameterValue(&quot;FromDate&quot;, dtpFromDate.Value.ToString(&quot;yyyy-MM-dd&quot;));
      Report.SetParameterValue(&quot;ToDate&quot;, dtpToDate.Value.ToString(&quot;yyyy-MM-dd&quot;));
      
      string orderBy = String.Empty;
      if (cboOrderBy.Text == &quot;Date&quot;)
        orderBy = &quot;DATE_FORMAT(`Date`,'%Y-%m-%d')&quot;;      
      else if (cboOrderBy.Text == &quot;Document #&quot;)      
        orderBy = &quot;TransID&quot;;      
      else if (cboOrderBy.Text == &quot;Client Name&quot;)
        orderBy = &quot;ClientName&quot;;
      else if (cboOrderBy.Text == &quot;Sales Rep&quot;)
        orderBy = &quot;SalesRep&quot;; 
      
      //For a specific client
      string forClient = &quot;ID &gt;= 0&quot;;
      if (cboClientName.Text != &quot;All&quot;)
        forClient = String.Format(&quot;ClientName = '{0}'&quot;, cboClientName.Text);
      
      TableDataSource tINV = Report.GetDataSource(&quot;credit_sales&quot;) as TableDataSource;
      TableDataSource tCN = Report.GetDataSource(&quot;credit_notes&quot;) as TableDataSource;
      TableDataSource tJNL = Report.GetDataSource(&quot;Journals&quot;) as TableDataSource;
      TableDataSource tRCPT = Report.GetDataSource(&quot;receipts&quot;) as TableDataSource;      
      
      tINV.SelectCommand = tINV.SelectCommand.ToString().Replace(&quot;@OrderBy&quot;, orderBy);           
      tCN.SelectCommand = tCN.SelectCommand.ToString().Replace(&quot;@OrderBy&quot;, orderBy);
      tJNL.SelectCommand = tJNL.SelectCommand.ToString().Replace(&quot;@OrderBy&quot;, orderBy);
      tRCPT.SelectCommand = tRCPT.SelectCommand.ToString().Replace(&quot;@OrderBy&quot;, orderBy); 
      
      tINV.SelectCommand = tINV.SelectCommand.ToString().Replace(&quot;@ForClient&quot;, forClient);           
      tCN.SelectCommand = tCN.SelectCommand.ToString().Replace(&quot;@ForClient&quot;, forClient);
      tJNL.SelectCommand = tJNL.SelectCommand.ToString().Replace(&quot;@ForClient&quot;, forClient);
      tRCPT.SelectCommand = tRCPT.SelectCommand.ToString().Replace(&quot;@ForClient&quot;, forClient); 
    }
    
    
    private void Child3_AfterData(object sender, EventArgs e)
    {
      txtTotExcl.Text = (Report.GetTotalValue(&quot;Total_Excl&quot;) - Report.GetTotalValue(&quot;Total_Excl_Refunds&quot;)).ToString();  
      txtTotVAT.Text = (Report.GetTotalValue(&quot;Total_VAT&quot;) - Report.GetTotalValue(&quot;Total_VAT_Refunds&quot;)).ToString(); 
      txtTotIncl.Text = (Report.GetTotalValue(&quot;Total_Incl&quot;) - Report.GetTotalValue(&quot;Total_Incl_Refunds&quot;)).ToString();
      
      //Format the total values
      //Use the tryParse method if there is no data to print
      decimal number = 0; 
      if (Decimal.TryParse(txtTotExcl.Text, out number)) 
        txtTotExcl.Text = Convert.ToDecimal(txtTotExcl.Text).ToString(&quot;# ###.00&quot;);
      if (Decimal.TryParse(txtTotVAT.Text, out number)) 
        txtTotVAT.Text = Convert.ToDecimal(txtTotVAT.Text).ToString(&quot;# ###.00&quot;);
      if (Decimal.TryParse(txtTotIncl.Text, out number)) 
        txtTotIncl.Text = Convert.ToDecimal(txtTotIncl.Text).ToString(&quot;# ###.00&quot;);
    }
    

    

    
  }
}
</ScriptText>
  <Dictionary>
    <MySqlDataConnection Name="Connection" ConnectionString="rijcmlqomabmqtwD7y3BaVO988XrjoBefSoHBX+xGSDpo0d+ot8yrzL17EhRvx7tW87ZuxDTsXprPmiOj80ATh2Aow+2w==">
      <TableDataSource Name="companies" DataType="System.Int32" Enabled="true" TableName="companies" SelectCommand="SELECT * FROM companies WHERE ID = @CompanyID">
        <Column Name="ID" DataType="System.UInt32"/>
        <Column Name="Name" DataType="System.String"/>
        <Column Name="Email" DataType="System.String"/>
        <Column Name="Address" DataType="System.String"/>
        <Column Name="RegNo" DataType="System.String"/>
        <Column Name="VATno" DataType="System.String"/>
        <Column Name="ContactNo" DataType="System.String"/>
        <Column Name="AltNo" DataType="System.String"/>
        <Column Name="FaxNo" DataType="System.String"/>
        <Column Name="CellNo" DataType="System.String"/>
        <Column Name="LogoPath" DataType="System.String"/>
        <Column Name="InvoiceStylePath" DataType="System.String"/>
        <Column Name="InvoiceSize" DataType="System.String"/>
        <Column Name="VATrate" DataType="System.String"/>
        <Column Name="BankingDetails" DataType="System.String"/>
        <CommandParameter Name="companyID" DataType="254" Expression="[CompanyID]"/>
      </TableDataSource>
      <TableDataSource Name="credit_sales" DataType="System.Int32" PropName="cash_sales" Enabled="true" TableName="credit_sales" SelectCommand="SELECT * FROM credit_sales &#13;&#10;WHERE CompanyID = @CompanyID AND DATE_FORMAT(`Date`,'%Y-%m-%d') BETWEEN DATE_FORMAT(@FromDate,'%Y-%m-%d') AND DATE_FORMAT(@ToDate,'%Y-%m-%d') &#13;&#10;AND @ForClient &#13;&#10;ORDER BY @OrderBy">
        <Column Name="ID" DataType="System.UInt32"/>
        <Column Name="CompanyID" DataType="System.UInt32"/>
        <Column Name="Date" DataType="System.DateTime"/>
        <Column Name="ComputerName" DataType="System.String"/>
        <Column Name="SalesRep" DataType="System.String"/>
        <Column Name="ClientID" DataType="System.UInt32"/>
        <Column Name="ClientName" DataType="System.String"/>
        <Column Name="SlipNote" DataType="System.String"/>
        <Column Name="Custom1" DataType="System.String"/>
        <Column Name="Custom2" DataType="System.String"/>
        <Column Name="Custom3" DataType="System.String"/>
        <Column Name="Custom4" DataType="System.String"/>
        <Column Name="Custom5" DataType="System.String"/>
        <Column Name="Custom6" DataType="System.String"/>
        <Column Name="TotalExcl" DataType="System.Decimal"/>
        <Column Name="TotalVAT" DataType="System.Decimal"/>
        <Column Name="TotalIncl" DataType="System.Decimal"/>
        <Column Name="TotalPaid" DataType="System.Decimal"/>
        <Column Name="TransID" DataType="System.UInt32"/>
        <Column Name="RelReceiptIDs" DataType="System.String"/>
        <Column Name="TotalCrNotesIncl" DataType="System.Decimal"/>
        <Column Name="RelCrNoteIDs" DataType="System.String"/>
        <Column Name="StatementNote" DataType="System.String"/>
        <Column Name="DeliveryAddress" DataType="System.String"/>
        <CommandParameter Name="companyID" DataType="254" Expression="[CompanyID]"/>
        <CommandParameter Name="fromDate" DataType="254" Expression="[FromDate]"/>
        <CommandParameter Name="toDate" DataType="254" Expression="[ToDate]"/>
        <CommandParameter Name="OrderBy" DataType="254"/>
        <CommandParameter Name="ForClient" DataType="254"/>
      </TableDataSource>
      <TableDataSource Name="credit_notes" DataType="System.Int32" PropName="cash_refunds" Enabled="true" TableName="credit_notes" SelectCommand="SELECT * FROM credit_notes &#13;&#10;WHERE CompanyID = @CompanyID AND DATE_FORMAT(`Date`,'%Y-%m-%d') BETWEEN DATE_FORMAT(@FromDate,'%Y-%m-%d') AND DATE_FORMAT(@ToDate,'%Y-%m-%d') &#13;&#10;AND @ForClient &#13;&#10;ORDER BY @OrderBy">
        <Column Name="ID" DataType="System.UInt32"/>
        <Column Name="CompanyID" DataType="System.UInt32"/>
        <Column Name="Date" DataType="System.DateTime"/>
        <Column Name="ComputerName" DataType="System.String"/>
        <Column Name="SalesRep" DataType="System.String"/>
        <Column Name="ClientID" DataType="System.UInt32"/>
        <Column Name="ClientName" DataType="System.String"/>
        <Column Name="SlipNote" DataType="System.String"/>
        <Column Name="TotalExcl" DataType="System.Decimal"/>
        <Column Name="TotalVAT" DataType="System.Decimal"/>
        <Column Name="TotalIncl" DataType="System.Decimal"/>
        <Column Name="TransID" DataType="System.UInt32"/>
        <Column Name="StatementNote" DataType="System.String"/>
        <CommandParameter Name="companyID" DataType="254" Expression="[CompanyID]"/>
        <CommandParameter Name="fromDate" DataType="254" Expression="[FromDate]"/>
        <CommandParameter Name="toDate" DataType="254" Expression="[ToDate]"/>
        <CommandParameter Name="OrderBy" DataType="254"/>
        <CommandParameter Name="ForClient" DataType="254"/>
      </TableDataSource>
      <TableDataSource Name="receipts" DataType="System.Int32" Enabled="true" TableName="receipts" SelectCommand="SELECT * FROM receipts &#13;&#10;WHERE CompanyID = @CompanyID &#13;&#10;AND IsForAccount = 1 &#13;&#10;AND DATE_FORMAT(`Date`,'%Y-%m-%d') BETWEEN DATE_FORMAT(@FromDate,'%Y-%m-%d') AND DATE_FORMAT(@ToDate,'%Y-%m-%d') &#13;&#10;AND @ForClient &#13;&#10;ORDER BY @OrderBy">
        <Column Name="ID" DataType="System.UInt32"/>
        <Column Name="CompanyID" DataType="System.UInt32"/>
        <Column Name="SalesID" DataType="System.UInt32"/>
        <Column Name="ClientID" DataType="System.UInt32"/>
        <Column Name="Date" DataType="System.DateTime"/>
        <Column Name="ClientName" DataType="System.String"/>
        <Column Name="AmountPaid" DataType="System.Decimal"/>
        <Column Name="PaymentMethod" DataType="System.String"/>
        <Column Name="IsForAccount" DataType="System.Byte"/>
        <Column Name="SalesRep" DataType="System.String"/>
        <Column Name="StatementNote" DataType="System.String"/>
        <Column Name="TransID" DataType="System.UInt32"/>
        <CommandParameter Name="CompanyID" DataType="254" Expression="[CompanyID]"/>
        <CommandParameter Name="FromDate" DataType="254" Expression="[FromDate]"/>
        <CommandParameter Name="ToDate" DataType="254" Expression="[ToDate]"/>
        <CommandParameter Name="OrderBy" DataType="254"/>
        <CommandParameter Name="ForClient" DataType="254"/>
      </TableDataSource>
      <TableDataSource Name="Table" Alias="Journals" DataType="System.Int32" Enabled="true" SelectCommand="SELECT * FROM debtor_journals &#13;&#10;WHERE CompanyID = @CompanyID &#13;&#10;AND DATE_FORMAT(`Date`,'%Y-%m-%d') BETWEEN DATE_FORMAT(@FromDate,'%Y-%m-%d') AND DATE_FORMAT(@ToDate,'%Y-%m-%d') &#13;&#10;AND @ForClient &#13;&#10;ORDER BY @OrderBy">
        <Column Name="ID" DataType="System.UInt32"/>
        <Column Name="CompanyID" DataType="System.UInt32"/>
        <Column Name="ClientID" DataType="System.UInt32"/>
        <Column Name="Date" DataType="System.DateTime"/>
        <Column Name="ClientName" DataType="System.String"/>
        <Column Name="Amount" DataType="System.Decimal"/>
        <Column Name="Reason" DataType="System.String"/>
        <Column Name="SalesRep" DataType="System.String"/>
        <Column Name="StatementNote" DataType="System.String"/>
        <Column Name="TotalPaid" DataType="System.Decimal"/>
        <Column Name="RelReceiptIDs" DataType="System.String"/>
        <Column Name="TransID" DataType="System.UInt32"/>
        <CommandParameter Name="companyID" DataType="254" Expression="[CompanyID]"/>
        <CommandParameter Name="fromDate" DataType="254" Expression="[FromDate]"/>
        <CommandParameter Name="toDate" DataType="254" Expression="[ToDate]"/>
        <CommandParameter Name="OrderBy" DataType="254"/>
        <CommandParameter Name="ForClient" DataType="254"/>
      </TableDataSource>
      <TableDataSource Name="Table1" Alias="clients" DataType="System.Int32" Enabled="true" SelectCommand="SELECT Name FROM clients WHERE CompanyID = @CompanyID &#13;&#10;ORDER BY Name">
        <Column Name="Name" DataType="System.String"/>
        <CommandParameter Name="CompanyID" DataType="254" Expression="[CompanyID]"/>
      </TableDataSource>
    </MySqlDataConnection>
    <Parameter Name="CompanyID" DataType="System.Int32"/>
    <Parameter Name="FromDate" DataType="System.String"/>
    <Parameter Name="ToDate" DataType="System.String"/>
    <Total Name="Total_Excl" Expression="[credit_sales.TotalExcl]" Evaluator="Data1"/>
    <Total Name="Total_VAT" Expression="[credit_sales.TotalVAT]" Evaluator="Data1"/>
    <Total Name="Total_Incl" Expression="[credit_sales.TotalIncl]" Evaluator="Data1"/>
    <Total Name="Count_Qty" TotalType="Count" Evaluator="Data1"/>
    <Total Name="Total_Excl_Refunds" Expression="[credit_notes.TotalExcl]" Evaluator="Data2"/>
    <Total Name="Total_VAT_Refunds" Expression="[credit_notes.TotalVAT]" Evaluator="Data2"/>
    <Total Name="Total_Incl_Refunds" Expression="[credit_notes.TotalIncl]" Evaluator="Data2"/>
    <Total Name="Count_Qty_Refunds" TotalType="Count" Evaluator="Data2" PrintOn="GroupFooter1"/>
    <Total Name="Total_Paid" Expression="[receipts.AmountPaid]" Evaluator="Data3"/>
    <Total Name="Count_Qty_Receipts" TotalType="Count" Evaluator="Data3"/>
    <Total Name="Total_Incl_Journals" Expression="[Journals.Amount]" Evaluator="Data4"/>
    <Total Name="Count_Qty_Journals" TotalType="Count" Expression="[Journals.ID]" Evaluator="Data4"/>
  </Dictionary>
  <inherited Name="Page1" Landscape="true" PaperWidth="297" PaperHeight="210" RawPaperSize="9" FirstPageSource="15" OtherPagesSource="15">
    <inherited Name="PageHeader1" Width="1047.06" Height="47.25">
      <inherited Name="_CompanyName"/>
      <ChildBand Name="Child1" ZOrder="-1" Top="51.25" Width="1047.06" Height="66.15">
        <TextObject Name="Text31" Left="18.9" Top="9.45" Width="680.4" Height="56.7" Text="Transactions - Account (All)" Font="Segoe UI Light, 22pt" TextFill.Color="OliveDrab"/>
        <TextObject Name="Text80" Left="841.05" Top="9.45" Width="189" Height="18.9" Text="[FromDate]" Format="Custom" Format.Format="d MMMM yyy"/>
        <TextObject Name="Text81" Left="841.05" Top="37.8" Width="189" Height="18.9" Text="[ToDate]" Format="Custom" Format.Format="d MMMM yyy"/>
        <TextObject Name="Text22" Left="727.65" Top="9.45" Width="94.5" Height="18.9" Text="From Date:" HorzAlign="Right" TextFill.Color="DimGray"/>
        <TextObject Name="Text23" Left="727.65" Top="37.8" Width="94.5" Height="18.9" Text="To Date:" HorzAlign="Right" TextFill.Color="DimGray"/>
      </ChildBand>
    </inherited>
    <GroupHeaderBand Name="GroupHeader2" ZOrder="0" Top="121.4" Width="1047.06" Height="94.5" RepeatOnEveryPage="true" Condition="[credit_sales.CompanyID]" SortOrder="None">
      <ShapeObject Name="Shape9" Top="9.45" Width="406.35" Height="47.25" Border.Color="Transparent" Fill="LinearGradient" Fill.StartColor="WhiteSmoke" Fill.EndColor="White" Fill.Angle="270" Fill.Focus="1" Fill.Contrast="0.89" Shape="RoundRectangle"/>
      <TextObject Name="Text83" Left="9.45" Top="18.9" Width="179.55" Height="28.35" Text="Credit Sales" Font="Segoe UI Light, 14pt" TextFill.Color="RoyalBlue"/>
      <ShapeObject Name="Shape7" Top="47.25" Width="1039.5" Height="37.8" Border.Color="Transparent" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
      <TextObject Name="Text15" Left="9.45" Top="56.7" Width="94.5" Height="18.9" Text="Date"/>
      <TextObject Name="Text14" Left="170.1" Top="56.7" Width="94.5" Height="18.9" Text="Document #" HorzAlign="Right"/>
      <TextObject Name="Text6" Left="548.1" Top="56.7" Width="141.75" Height="18.9" Text="User"/>
      <TextObject Name="Text8" Left="699.3" Top="56.7" Width="94.5" Height="18.9" Text="Total Excl" HorzAlign="Right"/>
      <TextObject Name="Text10" Left="803.25" Top="56.7" Width="94.5" Height="18.9" Text="Total VAT" HorzAlign="Right"/>
      <TextObject Name="Text12" Left="907.2" Top="56.7" Width="94.5" Height="18.9" Text="Total Incl" HorzAlign="Right"/>
      <TextObject Name="Text13" Left="274.05" Top="56.7" Width="94.5" Height="18.9" Text="Client Name"/>
      <DataBand Name="Data1" Top="219.9" Width="1047.06" Height="18.9" DataSource="credit_sales">
        <TextObject Name="Text3" Left="9.45" Width="151.2" Height="18.9" Text="[credit_sales.Date]" Format="Custom" Format.Format="yyy/MM/dd HH:mm"/>
        <TextObject Name="Text4" Left="274.05" Width="264.6" Height="18.9" Text="[credit_sales.ClientName]" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text5" Left="548.1" Width="141.75" Height="18.9" Text="[credit_sales.SalesRep]" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text7" Left="699.3" Width="94.5" Height="18.9" Text="[credit_sales.TotalExcl]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text9" Left="803.25" Width="94.5" Height="18.9" Text="[credit_sales.TotalVAT]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text11" Left="907.2" Width="94.5" Height="18.9" Text="[credit_sales.TotalIncl]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text1" Left="170.1" Width="94.5" Height="18.9" Text="[credit_sales.TransID]" HorzAlign="Right"/>
      </DataBand>
      <GroupFooterBand Name="GroupFooter2" Top="242.8" Width="1047.06" Height="56.7">
        <ShapeObject Name="Shape8" Top="9.45" Width="1039.5" Height="37.8" Border.Color="WhiteSmoke" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
        <TextObject Name="Text82" Left="18.9" Top="18.9" Width="160.65" Height="18.9" Text="Transaction Qty:" HorzAlign="Right" TextFill.Color="DimGray"/>
        <TextObject Name="Text16" Left="699.3" Top="18.9" Width="94.5" Height="18.9" Text="[Total_Excl]" Format="Number" Format.UseLocale="true" HorzAlign="Right"/>
        <TextObject Name="Text17" Left="803.25" Top="18.9" Width="94.5" Height="18.9" Text="[Total_VAT]" Format="Number" Format.UseLocale="true" HorzAlign="Right"/>
        <TextObject Name="Text18" Left="907.2" Top="18.9" Width="94.5" Height="18.9" Text="[Total_Incl]" Format="Number" Format.UseLocale="true" HorzAlign="Right"/>
        <TextObject Name="Text19" Left="189" Top="18.9" Width="94.5" Height="18.9" Text="[Count_Qty]"/>
      </GroupFooterBand>
    </GroupHeaderBand>
    <GroupHeaderBand Name="GroupHeader1" ZOrder="1" Top="307.5" Width="1047.06" Height="94.5" RepeatOnEveryPage="true" Condition="[credit_notes.CompanyID]" SortOrder="None">
      <ShapeObject Name="Shape14" Top="9.45" Width="406.35" Height="47.25" Border.Color="Transparent" Fill="LinearGradient" Fill.StartColor="WhiteSmoke" Fill.EndColor="White" Fill.Angle="270" Fill.Focus="1" Fill.Contrast="0.89" Shape="RoundRectangle"/>
      <TextObject Name="Text91" Left="9.45" Top="18.9" Width="179.55" Height="28.35" Text="Credit Notes" Font="Segoe UI Light, 14pt" TextFill.Color="Red"/>
      <ShapeObject Name="Shape10" Top="47.25" Width="1039.5" Height="37.8" Border.Color="Transparent" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
      <TextObject Name="Text84" Left="170.1" Top="56.7" Width="94.5" Height="18.9" Text="Document #" HorzAlign="Right"/>
      <TextObject Name="Text85" Left="548.1" Top="56.7" Width="141.75" Height="18.9" Text="User"/>
      <TextObject Name="Text86" Left="699.3" Top="56.7" Width="94.5" Height="18.9" Text="Total Excl" HorzAlign="Right"/>
      <TextObject Name="Text87" Left="803.25" Top="56.7" Width="94.5" Height="18.9" Text="Total VAT" HorzAlign="Right"/>
      <TextObject Name="Text88" Left="907.2" Top="56.7" Width="94.5" Height="18.9" Text="Total Incl" HorzAlign="Right"/>
      <TextObject Name="Text89" Left="274.05" Top="56.7" Width="94.5" Height="18.9" Text="Client Name"/>
      <TextObject Name="Text90" Left="9.45" Top="56.7" Width="94.5" Height="18.9" Text="Date"/>
      <DataHeaderBand Name="DataHeader1" Top="303.5" Width="1047.06" StartNewPage="true"/>
      <DataBand Name="Data2" Top="406" Width="1047.06" Height="18.9" DataSource="credit_notes">
        <TextObject Name="Text92" Left="9.45" Width="151.2" Height="18.9" Text="[credit_notes.Date]" Format="Custom" Format.Format="yyy/MM/dd HH:mm"/>
        <TextObject Name="Text93" Left="274.05" Width="264.6" Height="18.9" Text="[credit_notes.ClientName]" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text94" Left="548.1" Width="141.75" Height="18.9" Text="[credit_notes.SalesRep]"/>
        <TextObject Name="Text95" Left="699.3" Width="94.5" Height="18.9" Text="[credit_notes.TotalExcl]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text96" Left="803.25" Width="94.5" Height="18.9" Text="[credit_notes.TotalVAT]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text97" Left="907.2" Width="94.5" Height="18.9" Text="[credit_notes.TotalIncl]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text98" Left="170.1" Width="94.5" Height="18.9" Text="[credit_notes.TransID]" HorzAlign="Right"/>
      </DataBand>
      <GroupFooterBand Name="GroupFooter1" Top="428.9" Width="1047.06" Height="56.7" AfterDataEvent="GroupFooter1_AfterData" KeepChild="true">
        <ShapeObject Name="Shape12" Top="9.45" Width="1039.5" Height="37.8" Border.Color="WhiteSmoke" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
        <TextObject Name="Text99" Left="18.9" Top="18.9" Width="160.65" Height="18.9" Text="Transaction Qty:" HorzAlign="Right" TextFill.Color="DimGray"/>
        <TextObject Name="Text20" Left="699.3" Top="18.9" Width="94.5" Height="18.9" Text="[Total_Excl_Refunds]" Format="Number" Format.UseLocale="true" HorzAlign="Right"/>
        <TextObject Name="Text21" Left="803.25" Top="18.9" Width="94.5" Height="18.9" Text="[Total_VAT_Refunds]" Format="Number" Format.UseLocale="true" HorzAlign="Right"/>
        <TextObject Name="Text24" Left="907.2" Top="18.9" Width="94.5" Height="18.9" Text="[Total_Incl_Refunds]" Format="Number" Format.UseLocale="true" HorzAlign="Right"/>
        <TextObject Name="Text25" Left="189" Top="18.9" Width="94.5" Height="18.9" Text="[Count_Qty_Refunds]"/>
        <ChildBand Name="Child3" Top="489.6" Width="1047.06" Height="56.7" AfterDataEvent="Child3_AfterData">
          <ShapeObject Name="Shape13" Left="387.45" Top="9.45" Width="652.05" Height="37.8" Border.Color="Gainsboro" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
          <TextObject Name="txtTotIncl" Left="907.2" Top="18.9" Width="94.5" Height="18.9" Text="0.00" Format="Number" Format.UseLocale="false" Format.DecimalDigits="2" Format.DecimalSeparator="." Format.GroupSeparator=" " Format.NegativePattern="1" HorzAlign="Right"/>
          <TextObject Name="txtTotVAT" Left="803.25" Top="18.9" Width="94.5" Height="18.9" Text="0.00" Format="Number" Format.UseLocale="false" Format.DecimalDigits="2" Format.DecimalSeparator="." Format.GroupSeparator=" " Format.NegativePattern="1" HorzAlign="Right"/>
          <TextObject Name="Text103" Left="396.9" Top="18.9" Width="274.05" Height="18.9" Text="Totals (Sales - Notes):" HorzAlign="Right" TextFill.Color="DimGray"/>
          <TextObject Name="txtTotExcl" Left="699.3" Top="18.9" Width="94.5" Height="18.9" Text="0.00" Format="Number" Format.UseLocale="false" Format.DecimalDigits="2" Format.DecimalSeparator="." Format.GroupSeparator=" " Format.NegativePattern="1" HorzAlign="Right"/>
        </ChildBand>
      </GroupFooterBand>
    </GroupHeaderBand>
    <GroupHeaderBand Name="GroupHeader3" ZOrder="2" Top="554.3" Width="1047.06" Height="94.5" RepeatOnEveryPage="true" Condition="[receipts.CompanyID]" SortOrder="None">
      <ShapeObject Name="Shape15" Top="9.45" Width="406.35" Height="47.25" Border.Color="Transparent" Fill="LinearGradient" Fill.StartColor="WhiteSmoke" Fill.EndColor="White" Fill.Angle="270" Fill.Focus="1" Fill.Contrast="0.89" Shape="RoundRectangle"/>
      <TextObject Name="Text104" Left="9.45" Top="18.9" Width="179.55" Height="28.35" Text="Receipts" Font="Segoe UI Light, 14pt" TextFill.Color="OliveDrab"/>
      <ShapeObject Name="Shape16" Top="47.25" Width="1039.5" Height="37.8" Border.Color="Transparent" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
      <TextObject Name="Text105" Left="170.1" Top="56.7" Width="94.5" Height="18.9" Text="Document #" HorzAlign="Right"/>
      <TextObject Name="Text106" Left="548.1" Top="56.7" Width="141.75" Height="18.9" Text="User"/>
      <TextObject Name="Text109" Left="907.2" Top="56.7" Width="94.5" Height="18.9" Text="Amount Paid" HorzAlign="Right"/>
      <TextObject Name="Text110" Left="274.05" Top="56.7" Width="94.5" Height="18.9" Text="Client Name"/>
      <TextObject Name="Text111" Left="9.45" Top="56.7" Width="94.5" Height="18.9" Text="Date"/>
      <TextObject Name="Text113" Left="708.75" Top="56.7" Width="141.75" Height="18.9" Text="Payment Method"/>
      <DataHeaderBand Name="DataHeader2" Top="550.3" Width="1047.06" StartNewPage="true"/>
      <DataBand Name="Data3" Top="652.8" Width="1047.06" Height="18.9" DataSource="receipts">
        <TextObject Name="Text26" Left="170.1" Width="94.5" Height="18.9" Text="[receipts.TransID]" HorzAlign="Right"/>
        <TextObject Name="Text27" Left="9.45" Width="151.2" Height="18.9" Text="[receipts.Date]" Format="Custom" Format.Format="yyyy/MM/dd HH:mm"/>
        <TextObject Name="Text28" Left="274.05" Width="264.6" Height="18.9" Text="[receipts.ClientName]" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text29" Left="548.1" Width="141.75" Height="18.9" Text="[receipts.SalesRep]" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text32" Left="907.2" Width="94.5" Height="18.9" Text="[receipts.AmountPaid]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text34" Left="708.75" Width="151.2" Height="18.9" Text="[receipts.PaymentMethod]"/>
      </DataBand>
      <GroupFooterBand Name="GroupFooter3" Top="675.7" Width="1047.06" Height="56.7">
        <ShapeObject Name="Shape17" Top="9.45" Width="1039.5" Height="37.8" Border.Color="WhiteSmoke" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
        <TextObject Name="Text112" Left="18.9" Top="18.9" Width="160.65" Height="18.9" Text="Transaction Qty:" HorzAlign="Right" TextFill.Color="DimGray"/>
        <TextObject Name="Text37" Left="907.2" Top="18.9" Width="94.5" Height="18.9" Text="[Total_Paid]" Format="Number" Format.UseLocale="true" HorzAlign="Right"/>
        <TextObject Name="Text38" Left="189" Top="18.9" Width="94.5" Height="18.9" Text="[Count_Qty_Receipts]"/>
      </GroupFooterBand>
    </GroupHeaderBand>
    <GroupHeaderBand Name="GroupHeader4" ZOrder="3" Top="740.4" Width="1047.06" Height="94.5" RepeatOnEveryPage="true" Condition="[Journals.CompanyID]" SortOrder="None">
      <ShapeObject Name="Shape18" Top="9.45" Width="406.35" Height="47.25" Border.Color="Transparent" Fill="LinearGradient" Fill.StartColor="WhiteSmoke" Fill.EndColor="White" Fill.Angle="270" Fill.Focus="1" Fill.Contrast="0.89" Shape="RoundRectangle"/>
      <TextObject Name="Text114" Left="9.45" Top="18.9" Width="179.55" Height="28.35" Text="Journals" Font="Segoe UI Light, 14pt" TextFill.Color="DimGray"/>
      <ShapeObject Name="Shape19" Top="47.25" Width="1039.5" Height="37.8" Border.Color="Transparent" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
      <TextObject Name="Text115" Left="170.1" Top="56.7" Width="94.5" Height="18.9" Text="Document #" HorzAlign="Right"/>
      <TextObject Name="Text116" Left="548.1" Top="56.7" Width="141.75" Height="18.9" Text="User"/>
      <TextObject Name="Text117" Left="274.05" Top="56.7" Width="94.5" Height="18.9" Text="Client Name"/>
      <TextObject Name="Text118" Left="9.45" Top="56.7" Width="94.5" Height="18.9" Text="Date"/>
      <TextObject Name="Text119" Left="907.2" Top="56.7" Width="94.5" Height="18.9" Text="Amount" HorzAlign="Right"/>
      <TextObject Name="Text39" Left="699.3" Top="56.7" Width="94.5" Height="18.9" Text="Reason"/>
      <DataHeaderBand Name="DataHeader3" Top="736.4" Width="1047.06" StartNewPage="true"/>
      <DataBand Name="Data4" Top="838.9" Width="1047.06" Height="18.9" DataSource="Table">
        <TextObject Name="Text120" Left="170.1" Width="94.5" Height="18.9" Text="[Journals.TransID]" HorzAlign="Right"/>
        <TextObject Name="Text121" Left="9.45" Width="151.2" Height="18.9" Text="[Journals.Date]" Format="Custom" Format.Format="yyyy/MM/dd HH:mm"/>
        <TextObject Name="Text122" Left="274.05" Width="264.6" Height="18.9" Text="[Journals.ClientName]" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text123" Left="548.1" Width="141.75" Height="18.9" Text="[Journals.SalesRep]" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text124" Left="907.2" Width="94.5" Height="18.9" Text="[Journals.Amount]" Format="Number" Format.UseLocale="true" HorzAlign="Right" WordWrap="false" Trimming="EllipsisCharacter"/>
        <TextObject Name="Text35" Left="699.3" Width="198.45" Height="18.9" Text="[Journals.Reason]" WordWrap="false"/>
      </DataBand>
      <GroupFooterBand Name="GroupFooter4" Top="861.8" Width="1047.06" Height="56.7">
        <ShapeObject Name="Shape20" Top="9.45" Width="1039.5" Height="37.8" Border.Color="WhiteSmoke" Fill.Color="WhiteSmoke" Shape="RoundRectangle"/>
        <TextObject Name="Text125" Left="18.9" Top="18.9" Width="160.65" Height="18.9" Text="Transaction Qty:" HorzAlign="Right" TextFill.Color="DimGray"/>
        <TextObject Name="Text30" Left="189" Top="18.9" Width="94.5" Height="18.9" Text="[Count_Qty_Journals]"/>
        <TextObject Name="Text33" Left="907.2" Top="18.9" Width="94.5" Height="18.9" Text="[Total_Incl_Journals]" Format="Number" Format.UseLocale="true" HorzAlign="Right"/>
      </GroupFooterBand>
    </GroupHeaderBand>
    <PageFooterBand Name="PageFooter1" ZOrder="-1" Top="922.5" Width="1047.06" Height="37.8">
      <TextObject Name="Text36" Left="9.45" Top="9.45" Width="94.5" Height="18.9" Text="[PageNofM]" Font="Arial, 9pt" TextFill.Color="DimGray"/>
      <TextObject Name="Text79" Left="765.45" Top="9.45" Width="94.5" Height="18.9" Text="Print Date:" HorzAlign="Right" TextFill.Color="DimGray"/>
      <TextObject Name="Text78" Left="869.4" Top="9.45" Width="160.65" Height="18.9" Text="[Date]" TextFill.Color="DimGray"/>
    </PageFooterBand>
  </inherited>
  <DialogPage Name="Form1" ZOrder="1" Width="650" Height="382" AcceptButton="btnOk" CancelButton="btnCancel" ShownEvent="Form1_Shown">
    <ButtonControl Name="btnOk" Left="462" Top="291" Height="40" Anchor="Bottom, Right" Font="Segoe UI, 10pt" TabIndex="0" Text="OK" ClickEvent="btnOk_Click" DialogResult="OK"/>
    <ButtonControl Name="btnCancel" Left="545" Top="291" Height="40" Anchor="Bottom, Right" Font="Segoe UI, 10pt" TabIndex="1" Text="Cancel" DialogResult="Cancel"/>
    <DateTimePickerControl Name="dtpFromDate" Left="220" Top="96" Width="220" Height="27" Font="Segoe UI, 11pt" ForeColor="DimGray" TabIndex="2" Text="2 January 2014" CustomFormat="d MMMM yyy" Format="Custom" Value="01/02/2014 16:15:55"/>
    <DateTimePickerControl Name="dtpToDate" Left="220" Top="136" Width="220" Height="27" Font="Segoe UI, 11pt" ForeColor="DimGray" TabIndex="3" Text="2 January 2014" CustomFormat="d MMMM yyy" Format="Custom" Value="01/02/2014 16:14:02"/>
    <LabelControl Name="Label1" Left="72" Top="100" Width="74" Height="20" Font="Segoe UI Light, 11pt" TabIndex="4" Text="From Date"/>
    <LabelControl Name="Label2" Left="72" Top="136" Width="56" Height="20" Font="Segoe UI Light, 11pt" TabIndex="5" Text="To Date"/>
    <LabelControl Name="Label3" Left="16" Top="24" Width="307" Height="37" Font="Segoe UI Light, 20pt" ForeColor="OliveDrab" TabIndex="6" Text="Transactions - Credit Sales"/>
    <ComboBoxControl Name="cboOrderBy" Left="220" Top="228" Width="233" Height="28" Font="Segoe UI Light, 11pt" TabIndex="7" ClickEvent="" DropDownStyle="DropDownList" DropDownWidth="233" ItemHeight="20" ItemsText="Document #&#13;&#10;Date&#13;&#10;Client Name&#13;&#10;Sales Rep"/>
    <LabelControl Name="Label4" Left="72" Top="228" Width="116" Height="20" Font="Segoe UI Light, 11pt" TabIndex="5" Text="Order records By"/>
    <ComboBoxControl Name="cboClientName" Left="220" Top="188" Width="341" Height="28" Font="Segoe UI Light, 11pt" TabIndex="7" ClickEvent="" DataColumn="clients.Name" DropDownStyle="DropDownList" DropDownWidth="233" ItemHeight="20"/>
    <LabelControl Name="Label5" Left="72" Top="188" Width="68" Height="20" Font="Segoe UI Light, 11pt" TabIndex="5" Text="For Client"/>
  </DialogPage>
</inherited>
