Problm to Iterate the Rec vairble accrdng to Integer DataItm

tejateja Member Posts: 78
Hi Experts,

I am Designing a report in Navision LS Retail. The Report belongs to POS transactios. I mean when a transaction is made in sales the data is hitting to Trans. sales Entry Table . But f the if the Transaction is voided it is hitting to POs voided Transaction Table ...

Coming to my customization, The report should print Each and every Transaction that is voided and not voided ..

For example The Reciept No. 001 is Voided and from 002 to 009 is not voided and again from 011 n 012 are voided .. Taking this the report should print Each and every reciept no. in serial wise...

For doing this I selected Transaction Header. Because in this table all the transactions will hit, i.e Voided and not voided.. and Interger as Indented undented under Transaction Header..

I am counting the Trans.sales entry lines bssed on Reciept No. and making the Integer DataItem to Iterate that number of times ..

The Problem I am facing is the data coming from Trans. sales Entry and their Item details is printing only for one Item , every time Integer dataItem is Iterating .. Here Even though there are different Items in Trans. sales Entry there are different Items based in that resiept no.. It is priitning only one Item details for the whole report..


Please suggest me in solving this problem...](*,) ](*,) ](*,)

Thanks in Advance...
TEJA

Comments

  • NaviDevNaviDev Member Posts: 365
    Why not use the Transaction Header as your root an under it are the Trans. Sales Entry and POS Voided transaction. Link the two with child data item with the root (transaction no. will do). In the OnAfterGetRecord trigger of your Trans. Sales Entry check the status of your Transaction Header like
    IF "Transaction Header".Status = "Transaction Header".Status::Voided THEN
      CurrReport.SKIP;
    
    and in the OnAfterGetRecord trigger of your POS Voided transaction
    IF "Transaction Header".Status <> "Transaction Header".Status::Voided THEN
      CurrReport.SKIP;
    
    Navision noob....
  • EugeneEugene Member Posts: 309
    the data is entered into document type header/details tables "POS Transaction" and "POS Trans. Line"

    from there
    if sale is registered it goes to "Transaction Header" and "Trans. Sales Entry"
    if receipt is voided it goes to "Transaction Header" and "POS Voided Transaction" and "POS Voided Trans. Line"
    if some lines are voided but not the whole receipt it goes to "Transaction Header" and "POS Voided Trans. Line" (if i recall right "POS Voided Transaction" record is not created in this case)

    so your report should be based on "Transaction Header" and "POS Voided Trans. Line"

    if you want to print all voided lines you can not rely on "Transaction Header".Status=Voided because some voided lines can belong to not voided transaction.

    Our solution was to modify the code in such a way that "POS Voided Transaction" is always created even in case not the whole receipt but just one or several lines are voided. Then we were able to print the report based on "POS Voided Transaction" and "POS Voided Trans. Line"
Sign In or Register to comment.