Do you rename controls in Power Apps? Well of course you do! What if you have an app with many controls and they all use the out of the box names? It can becomes quite a task to name your controls properly. In this post the quick trick to get all controls renamed with Copilot within seconds.

Copilot in Power Apps

Did anybody say that Copilot in Power Apps isn’t useful? I’m sure I’ve said this in the past. But it is the small little features that make Copilot really useful.

Just imagine you have the following app. 7 Controls on a single screen may still be manageable but you could also have many more controls. Now, we can use a nice little features in Power Apps to do all the renaming for us.

Screenshot of a user interface displaying a tree view structure with options to Edit, Save, and Cancel, and a list of items: Orange, Apple, Banana, Grape.
Use Copilot to rename controls in Power Apps 1

Enable Copilot’s Proactive control rename

First of all we need to make sure that we enable one of the Copilot features.

Go to you settings within the app and select the Updates option inn the menu. Then Scroll all the way down until you get to Proactive control rename

Proactive control rename
Proactive control rename

When you create a new app this feature will be enabled by default. Have you ever considered what Preview means? In my opinion preview features should not be used in production and should be disabled by default. I guess nobody would try this feature if it wasn’t enabled by default.

Rename Controls using the Proactive Control rename

Once you have made sure that the feature has been enabled, we can go back to our app. In our treeview we just select one of the controls.

Poorly named controls in my app
Poorly named controls in my app

I’m going to select my text label that has been set to Grape and I’m going to rename it to lblGrape

Select a control in the app
Select a control in the app

As soon as I have renamed it, the Copilot icon appears (just like Clippy used to do in the 90s)

Copilot appears on the first rename
Copilot appears on the first rename

We can now click on the icon and the magic will happen. And even if my chosen prefix is different Copilot will pick up my standard really well.

Copilot suggests how to rename controls based on your first rename of a control
Copilot suggests how to rename controls based on your first rename of a control

Now all my labels have been renamed.

The prefix of your control sets the standard used
The prefix of your control sets the standard used

I can do the same thing for my buttons and all my controls have been renamed without it taking a lot of your time

Same control rename process for buttons
Same control rename process for buttons

So as you develop your app, should you still rename each control as you add it?


Discover more from SharePains

Subscribe to get the latest posts sent to your email.

Related Posts

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.