Skip to main content

Posts

Improved performance features of Business Central 17

  In the training I’ve done to some partners last week, when talking about performances I shared an example of an extension with 3 features that I think are not so well known but that have a significant impact on how your code performs, expecially on a SaaS environment. That extension used the following features: Partial record loading Temporary Tables QueryCategory The  Partial record  capability  is a new feature available starting from Dynamics 365 Business Central 2020 Wave 2 (v17) and I think it’s one of my top personal desiderata from years. This feature permits you to load only the needed fields of a recordset (when accessing a data source) instead of loading the entire set of fields. This is particularly useful on reports and OData pages because you can avoid to do a SELECT * (plus JOINS with all the extension’s tables) and instead doing a SELECT of only the fields you need. Now you can do something like: procedure TestPartialRecord(): Decimal ...
Recent posts

Dynamics NAV: How To Consume An External SOAP Web Service With .Net/Dotnet Interop

The reason for this blog post is that I needed to consume a web service from a partner company that give customer specific details. So far I haven’t worked with consuming web services in NAV so for me this is very new. This post is about the trial and errors that I had on the way implenting this in NAV 2015 on a Windows Server 2012 machine. My main objective was to solve this with dotnet interop. I started with googling it but for the most part I ended up with information about how to publish a web service from Dynamics NAV but I want to consume. After a while I realised there are a couple of ways of doing this. Use automation object (which I don’t want to do) Create a dotnet wrapper and handle it as an addin  (my Visual Studio skills aren’t the best) Use dotnet interop in NAV (Yes!) Eventually I found  this  post which seemed like it was exactly what I was looking but with only one problem. He was using the following dotnet librarys which I didn’t have  on the ...

Import Excel File Using Excel Buffer

  Hi All, This article is based on a friend request. The Requirement was to import the data in a table From an Excel File. Most of us know this feature is there in standard objects of Microsoft Dynamics NAV from a long time. If you are one of those who don't know about it please go through the article. Just for the Demo suppose i have a table where with following fields as shown below - And the file that i want to import looks like something as shown below - The Target is to import the data from excel in the Navision Table. I have Created a Page to view imported entries and on the same page there is an action of Import From Excel. For Importing data from Excel we will be using Standard  ReadSheet  Function in Excel Buffer Table in a Report. The Report will be Processing Only and will have options to Add the Entries or Replace the Entries. Below is the code that have been used to achieve desired result - First the Report Checks the option that user selected in Request Page...

How to Recover Dimension Set Entry Table from Dimension Set Tree Node Table?

Hi, Accidentally developer has forgot to set Temporary  = Yes for Record object of  Table 480 - "Dimension Set Entry". He created record variable for table 480 - dimension set entry : TempDimSetEntry - Record (Temporary = <No>) Then executed standard GetDimneisonSet function: DimMgt.GetDimensionSet(TempDimSetEntry,"Dimension Set ID"); And if run this code using developers license then it will delete all the records from Dimension Set Entr Table (because Temporary = False it should be True) This happen in UAT database of customer than it start giving error everywhere in the system and this impacted our UAT Session. But after analyzing and we found that we can create the dimension set entry from dimension set tree node table. Below is the Batch report which we used to create the dimension set entries from dimension tree node table. OBJECT Report 50000 CreateDimensionSetID {   OBJECT-PROPERTIES   {     Date=;     Time=;     Modified=Y...

Custom sheet name in RDLC Reports

Hi Readers, In this article we are going to discuss how to change the excel sheet name while using base Navision SAVEASEXCEL functionality. Applicable for RDLC reports of Navision and SSRS reports. Let’s say we have the following report that shows total sales by product category by territory:   When we export this report to Excel, we’d like each territory to appear in its own worksheet and each worksheet named after its territory: How do we make this work? Easy! 1) Put every group on its own page. 2) name each page using the same field the group uses. Step 1: Put each group on its own page To put each group on its own page, open the group’s property window. Then, in the Page Breaks category, put a check mark in the Between each instance of a group check box. Click OK to complete this step. Step 2: Name the pages of the group With the group selected in the Row Group s panel, press F4 to open the Properties window. Next, expand the Group ...

AL Development 03 - How to Develop New Report in AL?

Hi Readers, Now its time to develop the most important part of Navision which client desire the most yes you are correct i am talking about Reports. As we know to develop any solution in Business Central we must start working on AL Code Extension so from this blog you will get to know the detailed step how to create a Report through AL Code in business Central. Note: As of now there is no provision to customise the base report. Let’s try to create a simple report. Add new file with .al extension in your project folder through visual studio code My File Name is My_report.al  Code Snippet for adding a new Report, use snippet treport as shown below: Next Step to set these Report Properties - • Assign ID and Provide a name of the Report that you are adding. • Set UsageCategory to ReportsAndAnalysis. • Set ApplicationArea to All. As you select the treport snippet then a default structure of the report is created as below: Basically, there are 3...