Power Apps Studio tends to be more clever than we anticipate. Usually we can refer to screens, data, controls and other pieces of content within our Power Apps and rename them from the tree view or at source. However, as citizen developers we may want to rename a variable, collection, component or reference to something else.

Unfortunately, variables are often initialized (created) in the formula bar and Power Apps doesn’t know where to go looking to find where the origin is to rename it.

Luckily there is a hidden tool that we are all familiar with tucked inside the Power Apps Studio user interface…

Search

Currently in ‘preview‘ it can be found from the Upcoming Features list in your Power Apps settings. What Search allows us to do is enable a search pain in the authoring experience (Power Apps Studio) to search across formulas, variables, data sources and media.

After enabling this feature, a search icon (magnifying glass) will appear on the left hand side bar.

Find & Replace

Opening the search button we can see 2 tabs. Find and Replace. This works just like any other Find & Replace tool that you may have seen in programs such as Microsoft Word, Excel and Visual Studio.

We can use the Search box in the Replace tab to search for a keyword, and use the Replace with box to change it to something else.

In my example, I search for a variable named varColor and replace it with varPrimaryColor as I’ve decided to add more color variables to my app.

Completing this action, means all references in the formula bar throughout my entire app will now be replaced. Very useful for keeping your app working smoothly without breaking any formulas you have written.

About the author 

Connor Deasey (Collab365)