Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested answer

Extending or add the field to query page

(0) ShareShare
ReportReport
Posted on by 190

Dear Experts

i want to add Total Rem Qty(in all locn), unit price * qty and qty in transit into this subquery page or report. i cant able to get the code and no extension is listed over there to add it in dependencies.

how can we take the code and add those fields for getting the desired page or report

locationwise-item2554.jpg

  • LearnBC Profile Picture
    190 on at
    RE: Extending or add the field to query page

    Thanks for the reply Zhu

    am trying to bring one lookup field with the help of of your blog, but am getting error and not getting the desired output. kinldy request your kind help on this. i just want to select the value from dimensions values under the dimension name " item subcategory"

    tableextension 62000 "Item Sub Category" extends Item
    {
        fields
        {
            // Brought a new field to get the item sub category on Item Card Page
            field(62001; "Item Sub Cagetory "; Text[100])
            {
                DataClassification = ToBeClassified;
                Caption = 'Item Sub Category';

            }

        }
    }
    pageextension 62002 "Item Sub Category Code" extends "Item Card"
    {
        layout
        {
            addafter("Item Category Code")
            {
               
                field("Item Sub Cagetory "; Rec."Item Sub Cagetory ")
                {
                    ApplicationArea = All;
                    Caption = 'Item Sub Category Code';


                    trigger OnLookup(var Text: Text): Boolean
                    var
                        ItemRec: Record Dimension;

                    begin
                        ItemRec.Reset();
                        if Page.RunModal(Page::"Dimension Values", ItemRec) = Action::LookupOk then
                            Item Sub Cagetory := ItemRec.Name;
                    end;

                }
            }
        }

       
    }
  • Suggested answer
    YUN ZHU Profile Picture
    85,450 Super User 2025 Season 1 on at
    RE: Extending or add the field to query page

    Hi, you can unzip the app file I uploaded, there are these codes in the scr folder.

    Also, calculations are not supported in Query Object.

    You can use the following method to add to a new page.

    https://yzhums.com/4869/

    Hope this helps.
    Thanks.

    ZHU

  • LearnBC Profile Picture
    190 on at
    RE: Extending or add the field to query page

    Thank you for the Reply

    i can't able to see the extension in page extension and also i copied the dependency as you given in the blog and put in the app.json file then also its not downloading.

    how can i bring Total Rem Qty (in all locn), unit price * qty and qty in transit also in this

  • Suggested answer
    YUN ZHU Profile Picture
    85,450 Super User 2025 Season 1 on at
    RE: Extending or add the field to query page

    Hi, hope the following helps.

    How to download “_Exclude_Microsoft Dynamics 365 – Smartlist” extension source code (Such as query 2554 “Items By Location”)

    https://yzhums.com/10217/

    [View:/cfs-file/__key/communityserver-discussions-components-files/758/Microsoft_5F005F00_Exclude_5F00_Microsoft-Dynamics-365-_2D00_-SmartList_5F00_21.0.45833.0.app:320:240

    query 2554 "Items By Location"
    {
        QueryType = Normal;
        OrderBy = ascending (No);
        Caption = 'Items By Location';
        QueryCategory = 'Item List';
    
        elements
        {
    
            dataitem(Item; Item)
            {
                column(No; "No.")
                {
                    Caption = 'No.';
                }
    
                column(Description; Description)
                { }
    
                dataitem(Item_Ledger_Entry; "Item Ledger Entry")
                {
                    DataItemLink = "Item No." = Item."No.";
    
                    column(Location_Code; "Location Code")
                    {
                        Caption = 'Location Code';
                    }
    
                    column(Remaining_Quantity; "Remaining Quantity")
                    {
                        Caption = 'Remaining Quantity';
                        Method = Sum;
                    }
                }
            }
        }
    
        trigger OnBeforeOpen()
        begin
    
        end;
    }

    Thanks.

    ZHU

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

Ramesh Kumar – Community Spotlight

We are honored to recognize Ramesh Kumar as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
Sohail Ahmed Profile Picture

Sohail Ahmed 2,655

#2
Mansi Soni Profile Picture

Mansi Soni 1,574

#3
YUN ZHU Profile Picture

YUN ZHU 1,453 Super User 2025 Season 1

Featured topics

Product updates

Dynamics 365 release plans