D365 General Archives - Page 13 of 30 - - Page 13

Category Archives: D365 General

[Solved] – Backspace not working in HTML Web Resources

Issue: When we use a HTML web resource in Dynamics 365 CRM forms or even as a separate navigation, we sometimes face issue that Backspace on Text boxes do not work. Why this happens: This happens because in Custom HTML web resources, we add reference to “ClientGlobalContext.js.aspx”. We need this library to gain access to the global context information such as the information specific to the client, organization or user for your Customer Engagement instance* When we use this library, we get issues with backspaces on text boxes where Input type is not “text”. So if the HTML Input type is “number”, “search”, “tel” or anything else Resolution: Resolution 1:  This can be solved by changing the Input type as “Text” for all input textboxes. Then backspace will start working. But this may not be applicable in all scenarios, since it will remove some of the functionality that was intended. In that case, you can use Resolution #2 below. Resolution 2: I have been able to resolve this issue by running the following code on DOM ready: if (window.Sys && window.Sys.UI && window.Sys.UI.DomEvent && window.Sys.UI.DomEvent.prototype) { window.Sys.UI.DomEvent.prototype.preventDefault = function() { }; window.Sys.UI.DomEvent.prototype.stopPropagation = function() { }; } This will allow you to still use the functions that ClientGlobalContext provides, while keeping it from interfering with your key and mouse events. Credit: Stefan Boonstra  * ClientGlobalContext.js.aspx (Client API reference) Happy CRMing!

Share Story :

Dynamics 365 Tip: Sending Emails using Unified Interface

Introduction: The unified client which was released D365 V9 had a very refreshing UI and lots of features. One of the best features in Unified Interface was Timeline view, but the timeline view did not have ability to send emails. The Unified client has a new Email UI with rich text controls and advanced editor. This was not released till recently. So the new environments after v9.0.1.xx have the ability to send emails using the Unified Client. Now you can send Emails using Unified Client like below: Modern Email Editor: Below are some of the features of new Email Editor: Designer, HTML and Preview tabs will allow users to view and format the content across different form factors. A bunch of controls and features provided like advanced styling, linking, find and replace, and insert images and tables will be made available on the email activity and will allow users to format the email instead of relying on external tools or solutions. Note: The Email Editor is not available on D365 Phone App and App for Outlook. It will show all other activities but not email.

Share Story :

Filtering Records on BPF unlike on Form – D365

Introduction: Working with D365 is best when you’re trying to use as much OOB stuff as possible. Simplest configurations like selecting a view for your Lookup field is easily possible on the D365 Form. However, this is not possible on the fields on the Business Process Flow Use of addPreSearch() and addCustomFilter() on BPF Fields: Now, since you have this field on the BPF and want to add filter to Lookup records, you’ll need to use JS customization to achieve this and add your filter’s criteria in the code to show results as expected. Let’s say you see all the lookup records on the field on the BPF 2. I want to see only Semi Annually type of Plans on the Lead. And I can’t simply do this from the Field’s Properties like on the form. Because, it’s not available. 3. Hence, I’ll write JS code as follows to achieve this: // JavaScript source code var oOFFormCustomization = { preFiltering: function () { “use strict”; if (Xrm.Page.getControl(“header_process_cf_defaultplan”) != null) { Xrm.Page.getControl(“header_process_cf_defaultplan”).addPreSearch(oOFFormCustomization.preSearchProductFamily); } else return; }, preSearchProductFamily: function () { “use strict”; var fetchQuery = ‘<filter type=”and”>  <condition attribute=”cf_plantype” operator=”eq” value=”979570001″ /><condition attribute=”statecode” operator=”eq” value=”0″ /></filter>’; Xrm.Page.getControl(“header_process_cf_defaultplan”).addCustomFilter(fetchQuery); } }; 4. And I register the method on Page Load of the Form. 5. And I see these results once it successfully filters!

Share Story :

Filter records in gallery control based on value selected in other gallery control in PowerApps.

Introduction: This blog explains how to Filter records in gallery control based on value selected in other gallery control in PowerApps. Scenario: I am using Dynamics 365 Connection. I have data source named as Time Entry within that data source I have fields named as  Projects  and  Project task and data type of both fields is lookup. Values in Project Task is filtered based on value selected in Project field. Implementation Steps for Filtering Project Task based on Project: We must add Projects and Project Task data source in PowerApps because their data type is Lookup.(If you don’t know how to work with lookup fields Refer: https://www.cloudfronts.in/connect-dynamics-365-use-lookup-field-dynamics-crm-powerapps/ ) Add New screen name it Project Lookup and add gallery control on that screen. Select gallery control and set its item property to:SortByColumns(Search(Filter(Projects,statecode=0 ), TextSearchBox1_1.Text, “cf_name”), “cf_name” ) Add new Screen and name it Project Task Lookup and add gallery control on that screen. Select gallery control and set its item property to:SortByColumns(Search(Filter(‘Project Tasks’,     _cf_project_value =Gallery1.Selected.cf_projectid),TextSearchBox1_2.Text,”cf_name”),”cf_name”)here: Gallery1 is the name of gallery control on Project Lookup screen.

Share Story :

Business Process flows process stage name blank in D365 v9 Customer Engagement

Introduction: In this blog, we will demonstrate a way to display the current active stage of a business process flow in views in D365 v9 as the out of box process stage name field does not show any value in the views. Implementation: Step 1: We have created a basic Business Process flow on contacts which has two stages “Basic Information” and “Contact Details”. Step 2: If we want to create a view with the active stage of the business process flow displayed in the column, we first create a new view and in the Record Type we Select Process Stage(Process Stage) and in the columns we select “Process Stage Name” Step 3: Now when we check the view in Contacts we see that the Process Stage Name is blank. Step 4: One workaround for this is to design a Workflow on the Business Process flow entity that was created as shown in the below image . Here “Contact Infor” is the business process flow entity. Step 5: The workflow will be a Real time workflow and will be triggered when process is applied and on change of “processid” field. When the workflow triggers it will copy the name of the field in a new Text field and this can be used in views to display the current Stage as seen below.

Share Story :

D365 V9 Alert Dialog

Posted On April 25, 2018 by Admin Posted in

Introduction: This blog explains how to show alerts in D365 V9. Details: We often get requirement to show alerts in D365 V9 Forms and can be achieved using below syntax. Xrm.Navigation.openAlertDialog(alertStrings,alertOptions).then(closeCallback,errorCallback); Example: 1. Alert with no callbacks. var alertStrings = { text: “successfully checkedin.” }; var alertOptions = { height: 120, width: 260 }; Xrm.Navigation.openAlertDialog(alertStrings, alertOptions).then( function () { } ); 2. Alert with callback method. var alertStrings = { confirmButtonLabel: “Yes”, text: “This is an alert.” }; var alertOptions = { height: 120, width: 260 }; Xrm.Navigation.openAlertDialog(alertStrings, alertOptions).then( function success(result) { console.log(“Alert dialog closed”); }, function (error) { concole.log(error.message); } ); Note: Xrm.Utility.alertDialog(message,onCloseCallback) is been deprecated.

Share Story :

Calculated Currency Field doesn’t support Min or Max values

Introduction: This is an observation I made when one of our clients wanted to have a limit on the calculated fields. Let’s say, a lower limit of the currency field that is expected to throw an error (or somehow not allow) the currency going in negative values for a calculated field. Observation: Now, I want to keep the Minimum Value as $0. I’ll keep the Minimum value as 0 so that when I can make it as Calculated Field, the Minimum Value gets locked by $0 I’ve entered. See screenshot below: But, as soon as I make it as Calculated Field and click on Save, this happens- It still appears that I will save it as 0 But, it creates the field, locks the minimum field and then defaults it back to the original minimum value. Bottom line: We cannot have our own Minimum Value on the Calculated Currency fields. But however, I found that this is allowed for other calculated fields. Like the Whole Number.

Share Story :

How to Setup POP3/SMTP email configuration in Dynamics CRM

Introduction: This blog explains how to Setup POP3/SMTP email configuration in Dynamics CRM. Steps to be followed: Step 1:  Create new Email Server profile. a. Go to Settings –> Email Configuration –> Email Server Profile. b. Click on +New –> POP3/SMTP server. c. Fill Details in the form. Name: Gmail Incoming Server Location: pop.gmail.com Outgoing Server Location: smtp.gmail.com Now Go in Advanced Tab and Provide this Port values for Incoming and Outgoing Port. Incoming Port: 995  Outgoing Port: 587 d. Save. Step 2: Go to Email Configuration settings and then change Server Profile. Step 3:   a. Go to Mailboxes. b. Select the user for whom you want to activate. c. Add following details. Email Address: Enter your Gmail’s Email Address. In Credentials Allow to use Credentials for Email Processing and Provide your Gmail User Name and Password. d. Click on Approve Email e. Click on Test & Enable Mailbox. You may get following error. REASON: Due to hidden settings within Gmail that may be blocking connections from third party apps. SOLUTION:  a. Make sure you access these links while logged into the Gmail account, and make sure they’re turned on/enabled. https://www.google.com/settings/security/lesssecureapps https://accounts.google.com/DisplayUnlockCaptcha b. After enabling again go to mailbox and Click on Approve Email and Test & Enable Mailbox. c. Incoming and Outgoing Email Status is Success.

Share Story :

Calling unbound actions using Xrm.WebApi in D365 v9

Posted On April 25, 2018 by Clinton D'Mello Posted in Tagged in

Introduction: In this blog we will be demonstrating how to call an unbound action using Xrm.WebApi which provides properties and methods to use Web API to create and manage records and execute Web API actions and functions in Customer Engagement The available methods are createRecord, deleteRecord, retrieveRecord, retrieveMultipleRecords,execute and executeMultiple.The execute method executes a single action, function or CRUD operation. Implementation: The syntax for execute method is as follows: Xrm.WebApi.online.execute(request).then(successCallback,errorCallback); Note: This method isn’t supported for Unified Interface and it is only for online mode hence we have to use Xrm.WebApi.online object to execute the method, else it will fail. Step 1: First we create an unbound action. Here in our example we have created an action with the name “new_ActionTest” and we have activated it. In the action steps we have written a step to create a new contact with the name “Jessy David”. Here in our action we an Integer parameter. Any steps can be added as required. Step 2: Below shown code is function used to call the unbound action. Here “boundParameter” parameter is an optional String parameter, we have specified it as null as our action is not bound to any entity. “operationName” is an optional String parameter which is the name of the action.“operationType” is an optional Number parameter which indicates the type of operation we are executing is an Action hence we have specified 0. We can specific 1 for Functions and 2 for CRUD operations. When we run this, the action is called and a new contact is created according to the steps mentioned.

Share Story :

Filter records in PowerApps based on the current user of Dynamics CRM

Posted On April 10, 2018 by Admin Posted in

Starting from sales until delivery, Microsoft Dynamics 365 offers successful deployment of various business processes. The partners of Microsoft Dynamics 365 list the apps in the app source developed for a specific business need or for a particular business vertical hence showing their expertise. The dynamics 365 application development team has experts who are specialized in developing sophisticated business apps for their partners. The entire lifecycle of the business is supported through Microsoft Dynamics 365 right from developing the apps to listing them in the AppSource and giving support which lets you focus on the core business strategies instead of things which are less important. The qualified team of experts understand your requirements initially and then further work on improving each and every aspect of your business Introduction: This blog explains how to Filter records in PowerApps based on the current user of Dynamics CRM. Steps to be followed: Step 1: Add user entity. For that go to View –> Data sources –> Select Dynamics 365 connection. Select user entity –> click on connect. Step 2:  Now select Browse Screen and add Label control on Browse screen. Set its visible property to false. Set Text property to: LookUp(Users,internalemailaddress=User().Email,systemuserid) Step 3:  Select Browse Gallery and set its Items Property to : Search(Filter(Cases,_ownerid_value = Label1.Text), TextSearchBox1.Text, “description”) (Here Label1 is the name of Label which we have added in previous step && _ownerid_value stores the owner of that particular case record) I have selected _ownerid_values because owner field stores the user value according to which we want to filter the case records. By following above steps you will be able to filter records based on current user.

Share Story :

SEARCH BLOGS:

[gravityform id="36" ajax="true"]

FOLLOW CLOUDFRONTS BLOG :