Conditionally show an Image / Icon for an empty Field in a List applet
The requirement is to show an image when field in a List applet is empty or Null. Say, when an End Date is NULL on a record, other field should display an Icon/Image agianst the corresponding record.
Follow the below steps to implement this requirement:
1. Create a new Object for Bitmap Category and Bitmap to define the image file to be disaplyed when field is empty as shown in screenshot below:
Ensure the Filename called “icon_helptext.gif” is present in the folder called /Public/enu/Images folder.
2. Create a new Icon Map and Icon as shown in screenshot below:
For more information on Icon and Icon Map usage refer to the link below:
Icons child object refer to the Bitmap Category (BMC Custom) and Bitmap (BM Custom) created in Step1.
3. Go to your BC and create a new calculated field to evaluate the condition to display the image on the UI.
Name: Help Text
Calculated Value: IIF([End Date] IS NULL, “Yes”, “”)
Notes: “Yes” is used to display the corresponding Icon. Same value should be present in the Name Property of the Icons child object as defined in Step2.
4. Create a new List column in the Custom Appet as shown in figure below:
5. Modify the Web layout and expose this List column on the UI.
6. Compile all the objects such as Bitmap Category, Icon Map, BC and Applet and view the results in the UI as below: