cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PowerDigitize_1
Frequent Visitor

Save Image to OneDrive for Business

Hi, 

I have an image in image control that is generated using a web URL. 

"https://quickchart.io/chart?c={type:'bar',data:{labels:['Q1','Q2','Q3','Q4'], datasets:[{label:'Users',data:[50,60,70,180]},{label:'Revenue',data:[100,200,300,400]}]}}"

 

On click of button I am converting it into Binary and using Power Automate flow to save in OneDrive.

However, the file gets created but its blank.

 

Set(varimg, JSON(Image1.Image,JSONFormat.IncludeBinaryData)); TestCharts.Run(HtmlText1.HtmlText)

 

How can I save the image from Image Control in OneDrive for Business? 

2 REPLIES 2
WarrenBelz
Super User
Super User

Hi @PowerDigitize_1 ,

It is because the image control (which has many functions) is in this case is simply resolving an external URL, it does not contain an image generated by the App such as uploaded by Add Picture or captured by the Camera Control. I ran the same code as you and the output of the JSON code was this, so it is not possible to convert this to an image using base64ToBinary (or any other way).

WarrenBelz_0-1654380247574.png

 

 

 

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.

Visit my blog Practical Power Apps

 

 

WarrenBelz
Super User
Super User

Hi @PowerDigitize_1 ,

Just checking if you got the result you were looking for on this thread. Happy to help further if not.

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.

Visit my blog Practical Power Apps

Helpful resources

Announcements
Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on August 17, 2022 at 8am PDT.

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Users online (3,298)