Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics NAV (Archived)

Items For Selection

Posted on by 3,027

Hi

  In a report i have Purchase Receipt Header & Purchase Receipt Line . When i select No. filter in Purchase Receipt line list of items does not get displayed . How it can be done. Is it can be done in report itself.

Is it possible that in report Type = Item should be set as default in Purchase Receipt Line DataItem.

I have written below code but not working.

OnInit()

"Purch. Rcpt. Line".Type := "Purch. Rcpt. Line".Type :: 'Item';

Thanks

*This post is locked for comments

  • jsshivalik Profile Picture
    jsshivalik 3,027 on at
    RE: Items For Selection

    Hi

      In Purch Rcpt Line Item has following table relation

    IF (Type=CONST(G/L Account)) "G/L Account" ELSE IF (Type=CONST(Item)) Item ELSE IF (Type=CONST(Fixed Asset)) "Fixed Asset" ELSE IF (Type=CONST("Charge (Item)")) "Item Charge"

    In report if user does not select Filter Type from Purch Receipt Line DataItem then when user selects Item No filter from Purch Rcpt Line DataItem no list of items is displayed. If user selects filter Type then accordingly list is displayed when user selects Item No.

    Thanks

  • Suggested answer
    Stefano Demiliani Profile Picture
    Stefano Demiliani 37,162 Most Valuable Professional on at
    RE: Items For Selection

    This is not possible. The dataitem in request page shows all the possible values.

  • jsshivalik Profile Picture
    jsshivalik 3,027 on at
    RE: Items For Selection

    Hi

     It is a report . I want if on Request Page if user selects Purchase Receipt Line DataFilter Type then Item should be automatically displayed set as default when Request Page is loaded or user select Type Filter.

    Thanks

  • Suggested answer
    Stefano Demiliani Profile Picture
    Stefano Demiliani 37,162 Most Valuable Professional on at
    RE: Items For Selection

    Is this a report and you want to display lines with Type = Item? If so, you have to set a filter:

    “Purch. Rcpt. Line”.SETRANGE(Type,“Purch. Rcpt. Line”.Type::Item).

    If instead you want Type = Item set as default when creating a new line, in OnNewRecord set Rec.Type = Rec.Type::Item.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans