BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
PepeGuevara
Fluorite | Level 6

Hello everybody!

 

I have a dataset which have a field named photo and contains a base64 value that represents a photo. I would like to display in SAS Visual Analytics' report.

 

Any Idea about how can I display in a SAS Visual Analytics report?

 

Thanks in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
XavierBizoux
SAS Super FREQ

Hi,

Depending on how you want to display the image, you may want to opt for a Data-Driven Content object. 

The DDC object receives data from the report as any other object. You need to create an HTML page which receives the data and displays the base64 image. You can find examples of DDC object and code on different articles in the communities.sas.com. 

In your case, after receiving the data you should use JavaScript to generate the img tag(s). The src property of your image should look like this: 

 

src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4 //8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg=="

 

Let me know if you need more information about how to proceed. 

Regards,

Xavier

Xavier BIZOUX
Advisory Technical Architect ● Global Enablement and Learning
Technology Transfer and Governance, R&D

View solution in original post

1 REPLY 1
XavierBizoux
SAS Super FREQ

Hi,

Depending on how you want to display the image, you may want to opt for a Data-Driven Content object. 

The DDC object receives data from the report as any other object. You need to create an HTML page which receives the data and displays the base64 image. You can find examples of DDC object and code on different articles in the communities.sas.com. 

In your case, after receiving the data you should use JavaScript to generate the img tag(s). The src property of your image should look like this: 

 

src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4 //8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg=="

 

Let me know if you need more information about how to proceed. 

Regards,

Xavier

Xavier BIZOUX
Advisory Technical Architect ● Global Enablement and Learning
Technology Transfer and Governance, R&D

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

Tips for filtering data sources in SAS Visual Analytics

See how to use one filter for multiple data sources by mapping your data from SAS’ Alexandria McCall.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 856 views
  • 0 likes
  • 2 in conversation