- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2021 01:53 AM
Hello,
I have a field of type 'Image' which can take an image. I want to display this image on a widget I have. I tried showing it on the widget but it gives me a sys_id instead. How can I show it ?
Thanks
Solved! Go to Solution.
- Labels:
-
Service Desk
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2021 03:18 AM
Hello Anil,
No worries, I got it solved now. it should be
<img ng-src="{{::data.picture + '.iix'}}"/>
and in server script:
data.picture = grRec.getValue('u_image');
Thank you for the help Anil 🙂

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2021 02:03 AM
Hi,
If you have a image field on record then follow below steps:
In server side script where you have written glideRecord to get image use below logic:
data.picture = grRec.u_image;
and to display image in use below login in Widget HTML script:
<img ng-src="{{::data.picture}}"/>
Thanks,
Anil Lande
Thanks
Anil Lande
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2021 02:22 AM
Thank you Anil. I have implemented the same solution you suggested but it shows an empty braces brackets in the src field. If I also did data.picture = grRec.getValue(u_image); it will show a sys_id instead. What do you suggest?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2021 02:29 AM
Not sure if it is typo in community reply, but your need to correct below line
data.picture = grRec.getValue(u_image);
it should be:
data.picture = grRec.getValue('u_image');
Thanks,
Anil Lande
Thanks
Anil Lande
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2021 03:18 AM
Hello Anil,
No worries, I got it solved now. it should be
<img ng-src="{{::data.picture + '.iix'}}"/>
and in server script:
data.picture = grRec.getValue('u_image');
Thank you for the help Anil 🙂