Skip to main content

Posts

Showing posts from May, 2022

Database actions - PAD

  POWER AUTOMATE DESKTOP - DATABASE Pre-Requisites Power Automate Desktop Access to database  Under the database action, we have only three sub actions, namely: Open SQL connection Execute SQL statement  Close SQL connection Open SQL Connection The first step is to connect to the database. So, we will use the Open SQL connection action and provide a connection string to establish the connection (the connection string in the video is a sample). When the connection is successful, the connection details is stored in a variable during execution. Execute SQL statement This action can be used to execute SQL queries. Here, I am using select query and the result is stored in a variable of type datatable. Close SQL connection It is a best practice to always close the database connection once the required queries are executed. YAY! BONUS!😮 How to execute a stored procedure using database action? Stored Procedure without arguments Stored Procedure with arguments (Comma separated incase of many a

Filter A Gallery - Canvas App

 Filter A Gallery - Power Apps PRE-REQUISITE Login to your  Power Platform  account. Create a blank Canvas App. A Dataverse table with data in it is required to display as a data source in the gallery. FILTER A GALLERY STEP 1: Adding a vertical gallery to the canvas and select a data source (in this example, Pizzas table). STEP 2: Modifying the gallery controls. Click on the label on the first row to change. I changed the Text property from ThisItem.'Created On' to ThisItem.Crust. Note that all types of crusts are visible in the gallery. STEP 3: Now I will use the Filter - PowerFx to filter the gallery to display only the Pizzas which are of "Thin Crust". Filter ( DATASOURCE, FORMULA1, [, FORMULA 2, ...]); Use the filter function in the Data Source/Items property of the Gallery. Here, Pizzas  (a custom Dataverse table) is the Data Source and for the formula , I am checking if the text "Thin Crust" is available in the column Crust. Note that, as soon as the

PowerFx - SUM - Canvas App

 Sum Of Two Numbers - PowerApps I hope you get a clear idea on the usage of the Power Fx. PRE-REQUISITE Login to  PowerApps Create a Canvas App or Open an already existing  Canvas App BUILDING APP - USE LABELS AND SUM STEP 1: Add two "Text Input" into the Canvas. STEP 2:  Add a "Label"  into the Canvas. STEP 3: Use the SUM Power Fx. PLAYING THE APP TO SEE RESULTS We see how two numbers adds up and is displayed in the label. Please leave a comment, if you have any queries!

Gallery Control In Canvas App

 Gallery Control In Canvas App PRE-REQUISITE Login to  Power Apps Create a sample canvas app Create a Dataverse table and add data into it, or use an already existing table. 👉 Here's how to "Create Dataverse Table" GALLERY CONTROL If you have a table, with a number of columns, and having different datatype, then you use the Gallery control in the Canvas app to display it using the Label control. You can also add other Controls like Icons, Buttons, within a Gallery. When you make changes to the first row of a gallery, the changes are reflected to the rest of the rows in that gallery. TYPES OF GALLERY CONTROL IN CANVAS APP VERTICAL GALLERY This is how a vertical gallery looks like. By default, the gallery is given a default source "CustomGallerySample" to display. The gallery layout has an Image Control, an Icon and Two Label Controls, where one looks like Title & the other subtitle. CHANGE GALLERY LAYOUT CHANGE LAYOUT MANUALLY You may also change the layout

length ( ) - Cloud Flow

Finding length of string/array - Power Automate PRE-REQUISITE Login to  Power Automate Create a manually triggered instant flow An idea on  Array Variables  and  String Variables For this post, I will be using the String Team Kakashi and the Array ["Naruto","Sakura","Sasuke","Kakashi"] BUILDING FLOW - Length expression in Cloud Flow STEP 1: Create a string variable and assign a value. STEP 2:  Create an array variable and assign a value. STEP 3: Get the length of string using expression tab. length(variables('TextVar') STEP 4:  Get the length of array using expression tab. length(variables('ArrayVar')) QUICK NOTE: You can rename the actions in your flow, that helps better to understand it. TEST FLOW Length of string is 12 [Including the Space] Length of array is 4. That's all peeps!👋 Please leave a comment for queries!

Text Functions In Cloud Flow

 TEXT FUNCTIONS PRE-REQUISITE Login to  Power Automate Create a manually triggered instant cloud flow BUILD A FLOW TO USE TEXT FUNCTIONS Step 1: First, I will create a String variable called "varString" and give it a text value.  Step 2: Search "Text Functions" and select "Find Text Position". We can use this to find the position of a character or string within another string. From dynamic content, select the variable we created in previous step and provide a text to search. Step 3: Search "Text Functions" and select "Substring". This can be used to extract a substring from another string. From dynamic content, select the string variable that was created before, give a position from where the string has to be extracted and you may or may not give the length of the text that has to be extracted. TEST Here's the result of using "Find text position" and "Substring" Text Functions. Please leave a comment if you have

Do Until Control in a Cloud Flow

 How to use "Do Until" in a flow? PRE - REQUISITE Login to  Power Automate Create a manually triggered cloud flow DO UNTIL is a looping technique where a block of code/actions can be repeated until a condition is met and stopped once the condition is no longer met. For this flow, I will be using a variable with type integer. Here's a link, if you would like to review " Integer Variable " BUILDING THE FLOW - DO UNTIL IN POWER AUTOMATE STEP 1 : Create an integer variable and set default value as 0. STEP 2: Add Do until, select the variable, select "is greater than" and give the value 10. We are looping through the actions within this block until the condition "value of the variable is greater than 10" is met. Once the value touches 11 [as 11>10] , the loop is exited. [Note: The block of actions is executed first, then the condition is checked] STEP 3:  Now we add the block of action that has to be repeated. In this case, I will increment the