Posts

Showing posts from 2022

how to create Microsoft Teams group chat using power automate flow

Image
 Create a Automate trigger flow  When a record is Added or Modified or Delete on any of the custom entity Initialize a variable with Name: GroupName, Type: String, Value: Allam Teams Group this variable is used to check the existing team is available are not List chats Microsoft teams Chat Types: Group, Topic : All Chats  take a compose and value is contains(string(outputs( 'List_chats' )?[ 'body' ]),variables( 'GroupName' )) check the condition of compose output outputs('Compose') value Group "Allam Teams Group"  if group is already available then send a message in group or create group and send a message Create a chat Members to add :Test@onmicrosoft.com;Test2@onmicrosoft.com Title: Allam Teams Group Post message in a chat or channel Post as: Flow bot, Post in: Group chat, Group chat: Create a chat id, Message : type message if group is existing post message in a chat or channel2 as show in below output is as shown in below

How to create a responsible editable grid in canvas app using containers.

Image
We will show you how to create a Responsive Editable Grid in Canvas App as quick as possible with the Horizontal container and Vertical container. Login D365: https://make.powerapps.com/ Create a new Canvas App, click on Edit App. Part 1 : Create new Screen Rename Event Screen. Place a Vertical Container on the screen. Height= Parent.Height Width= Parent.Width Place a Horizontal Container for buttons inside Vertical Container on the screen. Flexible height off Height =50 Place a Horizontal Container for Table Header inside Vertical Container on the screen. Flexible height off Height =50 Inside a Horizontal Container place Horizontal Gallery Insert label 4 and rename the label inside of header container.   Moving on to EditableGridContentGallery(Blank Vertical Gallery) , insert 4 Text Inputs to the Container , rename all the Text Inputs accordingly and for each Text Input , we will map the X and Width property of each text input control to correspond with the Title

How to get application name using JS in D365

 When we run this, we see in passing a variable into the first parameter(appName),  it gives us several pieces of information, including the appId, displayName, uniqueName, url, webResourceId, webResourceName, welcomePageId and welcomePageName function appName() { var globalContext = Xrm.Utility.getGlobalContext(); globalContext.getCurrentAppProperties().then(     function success(app) { console.log(app); },  function errorCallback() { console.log("Error");  }); } async function CheckAppNameForSpecificValue() {     returnBoolVal = false;     var globalContext = Xrm.Utility.getGlobalContext();     await globalContext.getCurrentAppName().then(function (appName) {         if (appName.displayname.toLowerCase() == 'myappname') {             returnBoolVal = true         }     },         function (error) {             console.log('err ' + error.message)         });     return returnBoolVal; }

Validation on D365 and Key Points to be Identified/Noted in D365

  Whenever Business Unit Created Automatically Teams will created ------------------------------------------------- String field number validation can be done OOB functionality 000-00-0000 go to field control and formatting ------------------------------------------------- Parent Business Unit cannot change directly  first need to export excel change then name in excel and report import the excel file using (Settings->Data Management->Import) ------------------------------------------------- While creating an entity owner will not change like "user or team" / "organization"  if we are creating as Owner = organization then we cannot see share, Assign in Security Role then if we are creating as Owner = User or Team then we can see share, Assign in Security Role ------------------------------------------------- Two Type of Dashboard  1. Default 2. Interactive Dashboards In Dynamics 365, there are 2 types of Interactive Experience dashboards: Single-Stream Dashboa

How to set field validation to mobile number using JS in D365

 function onLoadEvents() {     Xrm.Page.getControl('mobilephonenumber').addOnKeyPress(AllowOnlyNumbers); } function AllowOnlyNumbers() {           var phoneNo = Xrm.Page.getControl("mobilephonenumber").getValue();     phoneNo = phoneNo.replace(/\D/g, '');     Xrm.Page.getAttribute('mobilephonenumber').setValue(phoneNo);     if (phoneNo.length == 11) {         var formattedPhone = phoneNo.replace(/(\d{3})(\d{3})(\d{4})/, '$1-$2-$3');         Xrm.Page.getAttribute('mobilephonenumber').setValue(formattedPhone);     } }

How to update/set lookup fields using Power Automate Flow

 By using Trigger outputs if(     empty(triggerOutputs()?['body/_apy_lookuprid_value']),     '',     concat(         'apy_lookupfieldname(',         triggerOutputs()?['body/_apy_lookupid_value'],         ')'     ) ) By Using Loop/ApplyToEach  if(     empty(items('Apply_to_each')?['_apy_lookupid_value']),     '',     concat(         'apy_lookupfieldname(',         items('Apply_to_each')?['_apy_lookupid_value'],         ')'     ) )

Copy Text Control using PCF In Power Apps

Image
Type any text in TextBox click on copy button and Paste any where on your computer. Please refer below Link https://github.com/TBag/power-apps-copy-text-to-clipboard#:~:text=import%20*%20as%20copy%20from%20'copy,handler%20for%20a%20button%20click.

How to Add a Popup for DELETE a record in Power Apps

Image
1. Login to PowerApps. 2. Open the APP 3. Create One Screen 4. Add One Gallery and DataSet is Account      In Gallery add one button which DELETE      OnSelect of DELETE button      Set(AccountDialog, true);      Set(AccountItem, ThisItem); 5. Take one Rectangle and Below values      Visible=AccountDialog      Fill=RGBA(0, 0, 0, .6)      Add one Label and 2 buttons 1. OK 2. Cancel 6. OnSelect of OK button      If(User().Email=AdminItem.'Grant Email to',Notify("You cannot revoke your own Access. Please           contact Admin."),Remove('Admin Users',AdminItem);Set(adminDialog,false))      7. OnSelect of Cancel button      Set(adminDialog,false)

how to get the XRM/FromContext on html page in D365.

Let’s image that you created a simple HTML web resource that needs to do some work and then pass it back to the form. Previously to do so you would use parent.Xrm. However, the problem is that previous parent.Xrm and Xrm.Page is deprecated. But know you have supported way to do so - welcome getContentWindow. syntax:  formContext.getControl(arg).getContentWindow().then(successCallback, errorCallback); 1. Create a java script webresource in Solution with below code. 2. Add the Event onLoad / OnChange on Entity Form and Pass Parameter. function Form_OnchangeOROnLoad(executionContext) {     var formContext = executionContext.getFormContext();     var wrControl = formContext.getControl("new_WebResourceName.htm");     if (wrControl) {         wrControl.getContentWindow().then(             function (contentWindow) {                 contentWindow.setClientApiContext(Xrm, formContext);             }         )     } } 3. Create Html WebResource in Solution wit below Code. 4. Add Html f