Latest Microsoft Dynamics 365 Blogs | CloudFronts - Page 6

How to retrieve a Sub-string from a String

Problem Statement:  We have a requirement where the client wants a part of String from Sales Order No. which is Code(Data type) and it is auto-generated from Number Series. The Sales Order No. value is “SO/123/789/456”. The required Sub-string was: 123<Space>789. Pre-requisites: VS Code AL Language Extension Microsoft Dynamics NAV /  Business Central Solution: As per the requirement, we need to first retrieve Sub-strings “123” and “789” and this can be achieved using SELECTSTR( ) function. But SELECTSTR() only retrieves a Sub-string from a comma-separated String. And the Sales Order No. string is a slash-separated string. So firstly we need to convert this string to comma-separated string, which is achieved in the below-presented screen. CONVERTSTR(String, From Characters, To Characters)   In the above Screen, “SalesOrder No.” is initialized in a text variable “SoNumber” and then is converted to a comma-separated string. The code is: CONVERTSTR( String: Text, FromCharacters: Text, ToCharacters: Text ) Now comes the part where we retrieve Substring from this converted String using SELECTSTR( ) function as the string is now converted into a comma-separated string, below screen shows how it is done. SELECTSTR(Number/Position, Comma-Separated String)   As you can see in the above screen how SELECTSTR() function is used to retrieve substring on the 3rd and 4th position of the String and stored in text variables “No1” and “No2” respectively. And these variables are then initialized to another variable with space. The code is: SELECTSTR(Position, Commastring); In the above example the code is: SELECTSTR(3, Separatenumber); SELECTSTR(4, Separatenumber);     Conclusion:  We can retrieve a comma-separated string or any other character-separated string using CONVERTSTR() and SELECTSTR() functions. Hope this helps!  

Share Story :

Attach Custom Generic event to lookup field (one or multiple same field) in D365 portals

Posted On December 27, 2019 by Admin Posted in

Sometimes we may get some requirements with multiple lookup fields on the same Entity form on D365 Portals. Also, we may have to perform some operations on click of search button on these Lookup fields. Here, it is not possible to achieve this without writing javascript or jquery code mean-while, we also have to make sure that the click event should be generic (single event working for all similar lookup fields). This blog will guide you to attach generic click event on all the similar lookup field using jquery. Below is the sample code for the same.   $(document).ready(function () { $(“.genericContact”).parent().find(“button[title=’Launch lookup modal’]”).each(function () {//click for all lookup $(this).click(function () { //your  code here }); }); }); In the above code, selector genericContact is a custom css class added to all the similar lookup fields on an entity form. To see how to add css class to any attribute click here.

Share Story :

Update Sub-form (Sub-Page) from Main Page to apply Filters.

Problem Statement: I have a requirement where I want to update the Subform(Part page) from the Main page, this Subpage(Subform) is linked to the Main page by SubpageLink Property. The Subpage is a List page and I want to filter this list by a field from Main Page. Pre-requisites: VS Code AL Language Extension Microsoft Dynamics NAV /  Business Central Solution: To solve the above Problem statement we have to make use of the Currpage.Update() function which shall update the Subpage. As you can see in the below window a function is created Vendorfilter() on Subpage with the “vendor” parameter, in this function filter is added for the vendor on the part page and then CurrPage.Update() is used. This function will update the Subpage with the vendor. Now, call this function on “OnValidate” trigger of the Main page field, here we have “Vendor” field on Main Page.     The calling of Function is as follows: CurrPage.<SubpageName>.Page.<FunctionName>(Rec.<FieldName>); In this example we have CurrPage.POLines.page.Vendorfilter(Rec.Vendor); Conclusion: Thus we can achieve updating a Subform from a Main Page. Hope this helps!

Share Story :

Power BI report using BYOD (Bring your Own Device)

Posted On December 19, 2019 by Admin Posted in

In this blog, we will learn how to create an Azure SQL database in Azure portal and export Finance and operation data into it. Steps: Go to www.portal.azure.com and create a new resource of SQL Database. Create New database, click on a new server and fill the necessary details, the login id and password will be the same that you will use to authenticate the database. Now the database is ready! You can click on Basic pricing tire to change the pricing of the database. Now copy the connecting string by clicking on Show database connection strings. Edit the string and add your id and password in it. Now go to finance and operations and open data management studio, click on Configure entity. Click on new and fill the required details. Name and description can be anything of your choice. Paste the connection string and click on validate. Once validated turn on the Enable triggers in target database toggle to ON. Now click on publish and select the entity that you want to export into your database. Click on change tracking and select enable entire entity. Now click on publish to publish the entity. This will detect the new added records in the table and export them to the database. On publishing, only the schema is exported to the database with entity name as a table name. Now again go to data management workspace and click on the export tab. Fill the name and description fields according to your wish and click on add entity. In add entity section enter the name of the entity that you have published earlier and selected the target entity, in our case it is the DemoBYOD. The refresh type should be incremental push only. Now the entity is added let’s export it. For that click on export in batch and set the recurrence according to your requirement. Set end date to no end date for the job to run for an infinite time. So the database is ready now let’s connect the database to Power BI! Open Power BI Desktop and click on get, select SQL Server database option. You already have the server name and database name with you! Select the required tables and load the data. All set you can start building your report! Hope this helps!

Share Story :

Business Central Wave 2 Features – Section 6

Introduction: In this blog, I will be attempting to provide information about the new Application Lifecycle Management features of Business Central Wave 2. Pre-requisites: Microsoft Dynamics Business Central Wave 2. Demonstration: 1.Report Production Outages in Administration Center.   Suppose there occurs a case where the user is having issues on Production Environment, in order to get help on such issues, the user can report such cases to Microsoft, this is achieved by visiting Admin Centre >> Environments >> and then click “Report Production Outage” as shown below.   After that fill in the details as shown below, i.e. Outage type, Name, Email address, Contact Number and on the next page fill in the details of errors and the time and date of Outage occurrence as shown below. When the user reports the Outage, a message is displayed with the ticket Number. Then the reported outage is displayed on the Reported Outages Menu as shown below: And the user gets an Email regarding the outage. 2. Multiple production environments New Business Central Wave 2 brings a new feature where users can have multiple Production Environments for different localizations. After creating multiple Productions when the user visits “home.dynamics.com”, the user is asked for which Production Environment he wants to visit as shown below.   3. Detailed Notification for Update Events The following image shows a detailed notification mail for the update events of Tenant. Hope this helps!

Share Story :

First cut review of new D365 Project Service

The new Project Service coming up is a much-advanced version of PSA. Even more, than it will be called as Project Service. We would learn about it and a few features that are exposed to the world shortly in the blog below. How to Install and Basic Requirement? The new project service can be installed on the Default environment of CRM. Now if this confuses you, let me explain. Every CRM environment has a Default CRM Instance associated to it. How to go and check it? Follow the below steps: Step 1: Ensure you have Project Plan 3 or Project Plan 5 license procured. Go to your admin portal and assign the license to your login id. Step 2: Login to https://admin.powerplatform.microsoft.com/ with your admin credentials. Step 3: Click on Environments. Before that ensure you toggle the switch to use “Try new admin centre”. Step 4: On the right-side pane, you will see a default environment mentioned as “Default” in front of the environment name. Click on it to see the URL of the environment. Step 5: Click on the URL to open the environment and below page will appear. Click on Project from the apps that you see.   You will be taken the Active Project view as shown below: Create a New Project In order to create a new project, click on +New Project button mentioned on the Ribbon Control. It will ask you for some basic details like Project Name, Project Manager and Calendar Template. As soon as you save the project, the estimated start date comes up as the current date. Next step is the plan the schedule (WBS) so we will navigate to Tasks. As soon as you click on tasks. It will take some time initially for the first time to connect to the project online services and you will see 3 tabs coming as shown below. Let’s look at each one of them one-by-one. Grid This is where you create your WBS, Assign Resources, Set Duration, Predecessor and many more. As soon as the task is created in the WBS. It creates a similar task on the Board (Explained below). Good Thing: a. We can mark the task as complete in new WBS with Project Service which was not the case in an earlier version (PSA). b. It is connected to the new Project Online Services so we can take advantage of the Project Online features right herewith. c. We can manage the project using the board which is much nice a feature. Needs Improvement: a. Here the Duration and efforts are tightly integrated to each other and in case one changes the other too changes. b. Boards should have allowed adding sprints in them, so we could even do Agile Project Management there. 2. Board This is where you can create tasks, to which the resources can be assigned. You can add Bucket (Swim lanes in Azure DevOps) to manage the state of the tasks. It also manages the progress of the task, Remaining effort, etc. 3. Timeline This is the Gantt Chart view of the tasks based on the efforts entered. What’s not available and when will it be available Currently, only the WBS or the Project Planning Module via Project Online is Exposed for General Availability. The sales extension and the invoicing piece is expected to be announced in Feb’2020. This blog reflects my personal findings and based solely on my experience of using Project Service for the last couple of months. For those who are looking for a platform that can track and manage the entire procedures of sales and project management, I would highly recommend them to try new Project Service as guided above.

Share Story :

Business Central Wave 2 Features – Section 4

Introduction: In this blog, I will be attempting to provide information about the new Modern Client features of Business Central Wave 2. Pre-requisites: Microsoft Dynamics Business Central Wave 2. Demonstration: Overview of All Business Central Features in Single Click. With the new release of Business Central comes a new feature where users can see all the features of Business Central in a Single Click. On the Dashboard, user can locate a “hamburger” next to Actions on the top right of the screen, when the user clicks on it, a new window is displayed that shows all the features of Business Central according to Profiles (Roles). The screen displayed in the above picture shows All features for “Cronus General Manager” which is personalized for that Role. The screen displayed above shows All features for Role – “Accountant”.   2. Identify your Companies with Badges. When users are working with multiple companies, it is possible that confusion about companies may occur, to keep things clear users can make use of this feature which can be achieved with the following steps:- Step 1: Go to Company Information and change “Company Badge” to “Custom”. Step 2: Select “Company Badge Style” from a range of 10 different colors available as shown below and write a four-letter “Company Badge Text” as shown. Now the user can see the company’s badge as created on the top right corner of the Dashboard. 3. Modern clients only for Business Central Users can work with Business Central in the browser, Windows 10 desktop app, or mobile apps on Android and iOS. With this release, Dynamics NAV Windows Client is no longer available. Windows 10 Desktop App: Mobile App:   Hope this helps!

Share Story :

Business Central Wave 2 Features – Section 5

Introduction: In this blog, I will be attempting to provide information about the new Modern Client features of Business Central Wave 2. Pre-requisites: Microsoft Dynamics Business Central Wave 2. Demonstration: Filter option fields by multiple values In the below picture, the user wants to apply a filter on an option field “Contact Type” on Customers, but the user can filter the data with either of the two options in Business Central. But with the new Business Central Wave 2 update, users can now filter option fields with multiple values as you can see below. 2. Multitasking across Multiple Pages: It is possible that users want to toggle between multiple pages, this feature was not available before, but it is possible in new Business Central Wave 2 update. Step 1: On the page, find the button highlighted below and click on the button that describes, “Open the page in a new window”. Step 2:  After Step 1 the page will open a new window as shown below. 3. Enter data with Speed and Agility Business Central wave 2 comes with more efficiency and agility,  data is entered with speed and agility, all the processing of fields in a record is done when the user adds a new record. 4. Longer timeout period for the server connection. In earlier versions of Business Central online, the session timeout period was set to 20 minutes. Microsoft has increased this value to two hours so that users are not asked to sign in to Business Central again and again. Note: This feature is only applicable to Business Central Online. For Business Central On-Premises, you can change the timeout in the Client Services tab in Business Central Server Administration. Hope this helps!

Share Story :

Numpad to remain on-screen in POS inventory receiving form in Dynamics 365 For Retail

This functionality was available in point of sale (POS) in Retail version 7.2. This functionality allowed for the numeric keypad (numpad) to appear at all times on the product receiving form. Having the numpad always available helps improve the efficiency of scanning product barcodes as part of POS receiving. This feature was removed after Retail version 7.3 due to screen redesign, but it has been brought back in all new releases. This functionality is enabled by default. You can access it from Picking and Receiving button on POS. Click on New button and the Numpad should open. Hope this helps !  

Share Story :

How to use System.Text.Json APIs in Asp.net

Posted On November 25, 2019 by Admin Posted in

Initially for parsing object to Json or json to object in Asp.net an additional Newtonsoft.Json Api was required, but now Microsoft has developed their own Apis “System.Test.Json”. Below Steps will guide you on how to use this api. Install the System.Text.Json NuGet package. To use the api make sure you import the following two namespaces: using System.Text.Json; using System.Text.Json.Serialization; Using the serializer as follows: The System.Text.Json serializer can read and write JSON asynchronously and is optimized for UTF-8 text, making it ideal for REST API and back-end applications. class WeatherForecast { public DateTimeOffset Date {get; set;} public int TemperatureC {get; set;} public string Summary {get; set;} }   string Serialize (WeatherForecast value) { return JsonSerializer.ToString<WeatherForecast>(value); } Api also support asynchronous serialization and deserialization. async Task SerializeAsync(WeatherForecast value, Stream stream) { await JsonSerializer.WriteAsync<WeatherForecast> (value, stream); } You can also use custom attributes to control serialization behavior, for example, ignoring properties and specifying the name of the property in the JSON: class WeatherForecast { public DateTimeOffset Date {get; set;}   // Always in Celsius. [JsonPropertyName(“temp”)] public int TemperatureC {get; set;}   public string Summary {get; set;}   // Don’t serialize this property. [JsonIgnore] public bool IsHot => TemperatureC >= 30; } Note: In the above point isHot property will not get parsed to json and json will look like below:      { “date”: “2013-01-07T00:00:00Z”, “temp”: 23, }

Share Story :

SEARCH BLOGS:

FOLLOW CLOUDFRONTS BLOG :


Secured By miniOrange