To get the filtered records in reords.

Hi All,

How do i pass the filtered records to a record variable in reports.

I am using Sales Invoice line table in a report and it is used for filtering purpose before taking the report. I am using a record variable of Sales Invoice Line ie recSalesInvLine.

Whatever filterations i have made , i have to transfer it in the record variable. for ex if i have given the filterations for date and “sell to customer No” before taking the report , recSalesInvLine also should also be filtered with date and “sell to customer No” .

I tried by using the code recSalesInvLine : = “Sales Invoice line” . in the Sales Invoice Line, Header section, But i am getting all the records . Filteration is not taking place.

Can anybody help me to solve this issue.

Thanks in advance


Hi Shib,

Try this…

1004.Shib001.bmp (231 KB)


And use these two variables where you want to filter the record recSalesInvLine.


you have to write code in Report-OnPrereport() section

FIlterrec := “sales invoice Line”.GETFILTERS;

where filterrec is a global variable Text 250

& now you can use this filterrec with variable silinvoicerec…take help of getfilters etc…

there are many reports which have done this on prereport section

example look report 129 Customer - Trial Balance…report on presection

Use recSalesInvLine.COPY(“Sales Invoice Line”). This one copies record, filters, marks and the sorting from SaleInvLine to recSalesInvLine*.*