Get the filtered records in a record variable in reports

shibilyshibily Member Posts: 89
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

Answers

  • BeliasBelias Member Posts: 2,998
    COPYFILTERS function, search it in online help (F1) :wink:
    and...don't use this in onaftergetrecord...use it after you have put all necessary filters to your variable
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
  • matttraxmatttrax Member Posts: 2,309
    Look at how printing an invoice works - PrintRecords function in Table 112.

    Basically you have to copy your record variable into another variable and pass that variable to the report.
  • mohana_cse06mohana_cse06 Member Posts: 5,504
    shibily wrote:
    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

    its working fine?
    which version u r using?
    in which section trigger did you write code?
  • shibilyshibily Member Posts: 89
    Yes it is working now. I have written in OnPreSection

    Regards
  • mohana_cse06mohana_cse06 Member Posts: 5,504
    shibily wrote:
    Yes it is working now. I have written in OnPreSection

    Regards

    y did u get problem before?
  • BeliasBelias Member Posts: 2,998
    He was assigning the variable instead of using COPYFILTERS, assignment does not copy the filters, but only the values...
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
  • mohana_cse06mohana_cse06 Member Posts: 5,504
    Belias wrote:
    He was assigning the variable instead of using COPYFILTERS, assignment does not copy the filters, but only the values...

    the values will assigning after applying filter.
  • BeliasBelias Member Posts: 2,998
    Belias wrote:
    He was assigning the variable instead of using COPYFILTERS, assignment does not copy the filters, but only the values...

    the values will assigning after applying filter.

    sorry, don't understand you :-k
    -Mirko-
    "Never memorize what you can easily find in a book".....Or Mibuso
    My Blog
  • mohana_cse06mohana_cse06 Member Posts: 5,504
    Belias wrote:
    Belias wrote:
    He was assigning the variable instead of using COPYFILTERS, assignment does not copy the filters, but only the values...

    the values will assigning after applying filter.

    sorry, don't understand you :-k

    he was assigning the variable means values

    the values are assigning after applying filter
  • navuser1navuser1 Member Posts: 1,329
    Hi Shib,

    Try this..


    And use these two variables to filter the record recSalesInvLine .


    Regards!
    Now or Never
  • shibilyshibily Member Posts: 89
    Hi all.
    My problem is solved by using the Copyfilter option.
Sign In or Register to comment.