Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Business Central forum

how to write visual studio code for create new page in 365 bc ?

(0) ShareShare
ReportReport
Posted on by 339

Hello all ,

how to write visual studio code for create new page in 365 bc ?i want to create new page like below screenshot file for 365 bc

0602.newpage-in-for-365bc.PNG

  • SABIH Profile Picture
    339 on at
    RE: how to write visual studio code for create new page in 365 bc ?

    Hello  Stefano Demiliani ,

    How to add manual values  in drop downlist using vs code,please help me

    dropdownlist_2D00_manualin-vs-code.PNG

  • Suggested answer
    Stefano Demiliani Profile Picture
    37,166 Most Valuable Professional on at
    RE: how to write visual studio code for create new page in 365 bc ?

    Exactly like I've done in the first field of the table definition I've posted. I don't know what table you want to refer but the key is TableRelation = .....

  • SABIH Profile Picture
    339 on at
    RE: how to write visual studio code for create new page in 365 bc ?

    Hello stefano ,

    Thank you very much for this

    but how to add table relation of below respective fields,i need table relation of this

    field(2;"Bill Code"; Code[20])

          {

              DataClassification = CustomerContent;          

          }

          field(3;"Control Account"; Code[20])

          {

              DataClassification = CustomerContent;          

          }

          field(4;"Percentage"; Decimal)

          {

              DataClassification = CustomerContent;          

          }

  • Suggested answer
    Stefano Demiliani Profile Picture
    37,166 Most Valuable Professional on at
    RE: how to write visual studio code for create new page in 365 bc ?

    Something like:

    Table:

    table 50100 MyTable

    {

       DataClassification = ToBeClassified;

       fields

       {

           field(1;"Account Category Code"; Code[20])

           {

               DataClassification = CustomerContent;

               TableRelation = "G/L Account Category";            

           }

           field(2;"Bill Code"; Code[20])

           {

               DataClassification = CustomerContent;          

           }

           field(3;"Control Account"; Code[20])

           {

               DataClassification = CustomerContent;          

           }

           field(4;"Percentage"; Decimal)

           {

               DataClassification = CustomerContent;          

           }

       }

       keys

       {

           key(PK; "Account Category Code")

           {

               Clustered = true;

           }

       }  

    }

    LIST PAGE:

    page 50100 MyList

    {

       PageType = List;

       ApplicationArea = All;

       UsageCategory = Lists;

       SourceTable = MyTable;

       layout

       {

           area(Content)

           {

               repeater(Group)

               {

                   field("Account Category Code"; "Account Category Code")

                   {

                       ApplicationArea = All;                    

                   }

                   field("Bill Code"; "Bill Code")

                   {

                       ApplicationArea = All;                    

                   }

                   field("Control Account"; "Control Account")

                   {

                       ApplicationArea = All;                    

                   }

                   field(Percentage; Percentage)

                   {

                       ApplicationArea = All;                    

                   }

               }

           }

       }

    }

    A list pag has automatically the features to edit record and to export it in an Excel file.

  • SABIH Profile Picture
    339 on at
    RE: how to write visual studio code for create new page in 365 bc ?

    Hello Stefano Demiliani ,

    Accordingly below screenshot could you please share me  vs code here ,that will be help more

    eachrowconsist.PNG

    eachrowconsist.PNG

    ac.PNG

  • SABIH Profile Picture
    339 on at
    RE: how to write visual studio code for create new page in 365 bc ?

    Hello Stefano Demiliani ,

    Accordingly that screenshot could you please share me  vs code here ,that will be help more

  • Suggested answer
    Stefano Demiliani Profile Picture
    37,166 Most Valuable Professional on at
    RE: how to write visual studio code for create new page in 365 bc ?

    Install the AL language extension, then start a new AL project by typing AL:Go! from command palette.

    You need to create a table object (snippet ttable), then a list page object (snippiet tpage) and then add the fields you want to that page.

    Start from here:

    docs.microsoft.com/.../devenv-get-started

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard > Business Central forum

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans