Showing results for 
Search instead for 
Did you mean: 
New Member

How to connect a button to AddMediaButton onSelect action



I have an AddMediaWithImage1 element that allows me to upload pictures in collection, it has AddMediaButton1 with the next onSelect function:

Collect(PhotoList, {Pic: UploadedImage1.Image, Name: Concatenate("File ", Text( Now(), "[$-en-US]yyyy/mm/dd hh:mm:ss" ), ".jpg")})


I would like to have a simple button that will refer to the AddMediaButton1 onSelect action. I need to press the button and after this AddMediaButton1 onSelect action happens. How can it be done?


Accepted Solutions
Not applicable

Yes, I did discover that. I found a workaround like in the reply above.

View solution in original post

Community Support
Community Support

Hi @StanR ,


Could you tell me :

  • Do you want to execute the formula of AddMediaButton1’ ‘s Onselect property by clicking a button ?


If the above assumption is true, the point is use select() function.

The function is used to refer to the Onselect property of another control.


You can try the following formula:

Add a button control to screen and set its Onselect property to:



Best Regards,


Super User III
Super User III

@StanR ,

As you have probably discovered, Select does not work on this control. I do not believe there is any way of initiating this control except pushing the button on it.


Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Not applicable

Yes, you understood correctly, but looks like this way did not work with AddMediaWithImage1 element, because when I pressed a new button it did not run camera or proposal to select a local picture, but added empty picture from UploadedImage1. Thanks, I customized the default AddMediaButton1 to make it be looked like a simple button, of course I could not do it the similar but anyway it solved my problem but I would say it was a workaround. 

Not applicable

Yes, I did discover that. I found a workaround like in the reply above.

View solution in original post

Helpful resources

PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (2,615)