web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Converting image data ...
Power Apps
Unanswered

Converting image data from Hexadecimal to Binary

(0) ShareShare
ReportReport
Posted on by 6

Hello, I am currently using the patch function to connect to my SQL database. I am actively passing all the data, but need to convert the IMAGEDATA to binary. I think i may be putting the hex2bin code in the wrong place ? Below is my patch function. 

Patch(
POWERAPPS_REQUESTWORKORDER_1,
Defaults(POWERAPPS_REQUESTWORKORDER_1),
{
FM: MYUSER,
CORPCODE: "EXFICORP",
CREATEDATE: Now(),
SITENAME: SITENAMEDataCardValue16.Selected.Value,
QR_ID: QRIDDataCardValue11.Text,
OPERATIONAL: OPERADataCardValue10.Value,
EQUIPMENT_NUM: EQUIPDataCardValue9.Text,
DESCRIP: DESCRIPDataCardValue14.Text,
APPROVAL_STATUS: false,
IMAGEDATA: First(RequestWO_Images).Value
}
);Reset(AddMediaButton1);
ResetForm(Form1);

Categories:
I have the same question (0)
  • CarlosFigueira Profile Picture
    Microsoft Employee on at

    What is the type of the column IMAGEDATA in your POWERAPPS_REQUESTWORKORDER_1 table? And what is the type of the values inside RequestWO_Images (i.e., how is that collection populated)? Sending images (such as those from the Add Picture control, or taken from a camera) to a column of type IMAGE or VARBINARY in SQL Server should just work, you shouldn't need to do any conversion in the Power Fx expression.

  • HeroFS Profile Picture
    6 on at

    In SQL IMAGEDATA is Varbinary(max), when I go to my values inside RequestWO_Images they are being stored as 'appres://blobmanager/9f624ee1145344abaebe0cec5eddaab5/1" and 'appres://blobmanager/9f624ee1145344abaebe0cec5eddaab5/2" etc.. and the image capture is coming from an ADD PICTURE control. The data does store at hexadecimal but for our purposes we need it to be in varbinary to use across other applications once the image is stored and hexadecimal is not compatible. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 358 Most Valuable Professional

#2
11manish Profile Picture

11manish 214 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 185

Last 30 days Overall leaderboard