Hello,
So I have written the logic for getting all invoice line amount of all item IDs of a particular group for each day and displaying it in the SSRS. Please check the below code and advise where i went wrong as it is not throwing any error but the report is not even displaying the column names.
Please advise.
While (queryrun.next())
{
_TM_GLTable.clear();
_CustInvoiceTrans = queryrun.get(tableNum(CustInvoiceTrans));
_date = _FromDate;
_noOFDayes = _ToDate - _FromDate;
_totalamt =0;
for(i=1;i>=_noOfDayes;i++)
{
while select * from _inventItemGroupItem where _inventItemGroupItem.ItemGroupId == _ItemGroupId
{
select sum(LineAmount) from _custInvoiceTrans where _custInvoiceTrans.ItemId == _inventItemGroupItem.ItemId
&& _custInvoiceTrans.InvoiceDate == _date ;
_totalAmt += _custInvoiceTrans.LineAmount;
}
_TM_GLTable.initValue();
_TM_GLTable.InvoiceDate = _date;
_TM_GLTable.LineAmount= _totalAmt;
_TM_GLTable.insert();
_date = _date+1;
}
}
*This post is locked for comments