Programmer:Debtor Aging (19): Difference between revisions

no edit summary
(Created page with "==References of AutoCount Accounting version 1.8 / 1.9== {{BaseReferenceAC18}} '''BCE.AutoCount.ARAP.dll''' ==Extract data of AR Debtor Aging with API== The sample code belo...")
 
No edit summary
 
(One intermediate revision by the same user not shown)
Line 4:
 
==Extract data of AR Debtor Aging with API==
The sample codeExamples below shows how to retrieve DataSet or DataTable of Debtor Aging.
It filters result of:
#Up to Today's date;
#Debtor code range of "300-A001" and "300-C999";
#and does not include debtor whom the balance is zero.
 
===Aging DataSet===
<syntaxhighlight lang="csharp">
public System.Data.DataSet DebtorAgingTableDebtorAgingDataSet(BCE.Data.DBSetting dbSetting)
{
BCE.AutoCount.ARAP.DebtorAging.DebtorAging aging = BCE.AutoCount.ARAP.DebtorAging.DebtorAging.Create(dbSetting);
Line 32 ⟶ 34:
}
</syntaxhighlight>
 
* Tables in Aging DataSet
[[File:Prog.AR.AgingDataSet.png|link=]]
 
===Aging Detail Table===
<syntaxhighlight lang="csharp">
public System.Data.DataTable DebtorAgingTable(BCE.Data.DBSetting dbSetting)
{
BCE.AutoCount.ARAP.DebtorAging.DebtorAging aging = BCE.AutoCount.ARAP.DebtorAging.DebtorAging.Create(dbSetting);
BCE.AutoCount.ARAP.DebtorAging.DebtorAgingCriteria crit = new BCE.AutoCount.ARAP.DebtorAging.DebtorAgingCriteria();
 
//There are many more criteria to filter the result
crit.ReportDate = DateTime.Today.Date;
crit.DebtorFilter.ByRange("300-A001", "300-C999");
crit.IncludeZeroBalance = false;
 
//The return table is "Master"
DataTable tblAging = aging.Inquire(crit);
 
return aging.ResultDataSet.Tables["Detail"];
}
</syntaxhighlight>
* Columns in Aging.Detail Table.
[[File:Prog.AR.AgingDetailTable.png|link=]]
 
{{SeeAlsoAPIReport}}
[[Category:Programmer]]