Personalized Community is here!
Quickly customize your community to find the content you seek.
Have questions on moving to the cloud? Visit the Dynamics 365 Migration Community today! Microsoft’s extensive network of Dynamics AX and Dynamics CRM experts can help.
2022 Release Wave 1 PlanDynamics 365 release plan for the 2022 release wave 1 describes all new features releasing from April 2022 through September 2022.
2022 release wave 1 plan
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Community | FastTrack Program | Finance and Operations TechTalks | Customer Engagement TechTalks | Upcoming TechTalks | All TechTalks
In the previous post, I wrote about how we can use C# code in Power Automate connectors now. The example given there (converting a string to uppercase) was not that useful, of course, since we could simply use an expression and a “toUpper” function directly in the expression.
So I thought of a more useful application of this new functionality, and, it seems, sorting string arrays might be one of those.
Mind you, it can be done without c# code. For example we could run an office script:
Which looks like a valid option (it’s coding anyways), but, if we did not want to use office connectors (or, perhaps, for those of us who would prefer C#), it can also be done with C# using “code” functionality in the custom connector:
You will find both swagger definition and script files for this connector in the git repo:
And there are some explanations below
1. SortStringArray operation will have arrays as both input and output parameters
2. In the code, incoming array will be converted into a string array, then sorted, then sent back through the response
That’s quick and simple; although, I have to admit it took me a few hours to figure out all the plumbing (swagger definitions, using JArray above, etc). But, I guess, it’s fine to expect a bit of a learning curve initially.
What definitely helped, though, is creating a small project in the Visual Studio and testing some of the same code there.
Anyways, that’s all for now!
Business Applications communities