Skip to main content

Notifications

Announcements

No record found.

Business Central forum
Suggested answer

Open Page - with - Filters - visible to the user

Posted on by 23
Hello Community,
 
i have got the following question.
I want the user to be able to open a page via click on a Field. 
If he clicks on the Field i want the page for contacts to open.
However i am setting Filter via Set Range so only certain contacts should be shown to the user. 
That is easy. 
 
However i want the user to be able to see the Filter which i have entered and i want the user to be able to change the filter. 
These should be possible if the user opens the page and wants to change the filter.
 
I have already found these functionalities in Business Central however i am not able to copy it.
 
What i want is this:
 
What i get instead: 
 
This would be my latest try
                    ApplicationArea = All;
                    trigger OnDrillDown()
                    var
                        Contact: Record Contact;
                        ContactList: Page "Contact List";
                    begin
                        Contact.Reset();
                        Contact.SetRange("Reference Contact", Rec."Sell-to Contact No.");
                        Page.RunModal(Page::"Contact List", Contact)
                    end;
 
 
I have read these:
 
Dear Community Please Help!
Categories:
  • Open Page - with - Filters - visible to the user
    @YUN ZHU @gdrenteria
    Thank you for your replies.
    I have found a solution through combination of different methods.
     
  • Suggested answer
    YUN ZHU Profile Picture
    YUN ZHU 63,522 Super User on at
    Open Page - with - Filters - visible to the user
    This requires using the function in the Page to pass the value in. Here is a simple example that I hope will give you some hints.
     
    And
     
    Thanks
    ZHU
     
  • Open Page - with - Filters - visible to the user
    @Yun ZHU
     
    thanks for your post. 
    This seems to be the right way.
    However, now i have another question.
    I want to be able to choose an entry of this page and take the information and assign them
    to the Field.
    Now if i click on one entry i get directed to the card page.
     
     
    and assign them here:
     
     
     
  • Suggested answer
    YUN ZHU Profile Picture
    YUN ZHU 63,522 Super User on at
    Open Page - with - Filters - visible to the user
    Hi, Below is an example of opening Item Ledger Entries, I hope it can give you some hints.
    pageextension 50201 ItemListExt extends "Item List"
    {
        layout
        {
            modify(InventoryField)
            {
                trigger OnDrillDown()
                var
                    ItemLedgerEntry: Record "Item Ledger Entry";
                begin
                    ItemLedgerEntry.Reset();
                    ItemLedgerEntry.SetRange("Item No.", Rec."No.");
                    ItemLedgerEntry.SetRange("Entry Type", ItemLedgerEntry."Entry Type"::Purchase);
                    if not ItemLedgerEntry.IsEmpty then
                        Page.Run(Page::"Item Ledger Entries", ItemLedgerEntry);
                end;
            }
        }
    }
     
    Thanks
    ZHU
  • gdrenteria Profile Picture
    gdrenteria 4,646 Super User on at
    Open Page - with - Filters - visible to the user
    Hi
    Have you tried coding the OnLookup event, or duplicating the standard ContactList page?
    BR
    GR

Helpful resources

Quick Links

First Dynamics 365 Community Call (CRM Edition)

Don't miss the first D365 Community Call on 7/10!

Community Spotlight of the Month

Kudos to Saurav Dhyani!

Congratulations to the June Top 10 community leaders!

These stars go above and beyond . . .

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 285,642 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 225,485 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans