Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Developer
Nitish_Pheonix
Posts: 29
Registered: ‎09-17-2012
My Device: 9810, 9800, 9700, 9900, 9300
My Carrier: BSNL
Accepted Solution

Get the picture path from the contact for webworks smartphone

Hi All,
I am trying to get the picture path from the contact in address book.
I am getting the title, firstName etc successfully.
But I can't find such code from which I can get the path of particular contact picture.

Please help me if anyone know the code or having any solution As Soon As Possible.

Thanks & Regards,
Himansu

Thanks & Regards,
Nitish_Pheonix

Hit like if the above post is helpful to you.
Please Accept this as Solution if the above post is a solution for you.
Please use plain text.
BlackBerry Development Advisor (Retired)
mimendoza
Posts: 64
Registered: ‎06-04-2012
My Device: Blackberry Z10
My Carrier: Bell

Re: Get the picture path from the contact for webworks smartphone

You can retrieve the image object as a base64 encoded string, but won't receive the file path (API Reference). To display the image you can use a data URI along with an <img> tag.

 

Example on how to use data URI: http://css-tricks.com/data-uris/

----------------------------------------------------------------------------------
- Did this post help solve the issue? Click on "Accept as Solution"
- Was the content of this post helpful? Please give it a "Thumbs Up"

developer.blackberry.com
@BlackBerryDev
Please use plain text.
Developer
Nitish_Pheonix
Posts: 29
Registered: ‎09-17-2012
My Device: 9810, 9800, 9700, 9900, 9300
My Carrier: BSNL

Re: Get the picture path from the contact for webworks smartphone

Hi mimendoza,
I got through the code and it's little bit complicated..
Please can you provide some sample code to retrieve the image.

i got stock with thie problem.

Thanks & Regards,

Himansu

Thanks & Regards,
Nitish_Pheonix

Hit like if the above post is helpful to you.
Please Accept this as Solution if the above post is a solution for you.
Please use plain text.
Developer
Nitish_Pheonix
Posts: 29
Registered: ‎09-17-2012
My Device: 9810, 9800, 9700, 9900, 9300
My Carrier: BSNL

Re: Get the picture path from the contact for webworks smartphone

Hi 

I figure out the problem I am facing and able to retrieve the image to my custom contact list.

Thanks & Regards,

Himansu

Thanks & Regards,
Nitish_Pheonix

Hit like if the above post is helpful to you.
Please Accept this as Solution if the above post is a solution for you.
Please use plain text.
BlackBerry Development Advisor (Retired)
mimendoza
Posts: 64
Registered: ‎06-04-2012
My Device: Blackberry Z10
My Carrier: Bell

Re: Get the picture path from the contact for webworks smartphone

Glad to hear that this method worked for you.

----------------------------------------------------------------------------------
- Did this post help solve the issue? Click on "Accept as Solution"
- Was the content of this post helpful? Please give it a "Thumbs Up"

developer.blackberry.com
@BlackBerryDev
Please use plain text.