Blog Post

The Qrew Blog
1 MIN READ

Multiselect field values with customized bullet colors

BhargaviKatepa1's avatar
BhargaviKatepa1
Qrew Member
2 years ago

Hi , 

I am trying to show a multiselect values with customized bullet color list using rich text field. But unfortunately I caanot , by default it is taking the black bullets not able to do the customization , can someone help me here. I just used the below code, there are 10 values in my multiselct field I want that to be represented with different color of bullets.

If(ToText([Workstream])="","",
     "<li>" & 
     SearchAndReplace(ToText([Workstream]),";","</li><li>") &
     "</li>" )



------------------------------
Bhargavi Katepalli
------------------------------
Published 2 years ago
Version 1.0

4 Comments

  • MeredithMoore5's avatar
    MeredithMoore5
    Qrew Assistant Captain

    Well there are a few solutions to this. But if you want all the control I would do a Manual Parse. You can add "IF" statements to control the colors or if you just want it to be in a pretty order then you can do that too.

    Manual Parse (10 Item List)

    var text Items = ToText([Workstream]);

    List("</br>",

    "<span style='color:red'>&#149; </span>"&Part($Items,1,";"),

    "<span style='color:orange'>&#149; </span>"&Part($Items,2,";"),

    "<span style='color:yellow'>&#149; </span>"&Part($Items,3,";"),

    "<span style='color:green'>&#149; </span>"&Part($Items,4,";"),

    "<span style='color:blue'>&#149; </span>"&Part($Items,5,";"),

    "<span style='color:purple'>&#149; </span>"&Part($Items,6,";"),

    "<span style='color:red'>&#149; </span>"&Part($Items,7,";"),

    "<span style='color:orange'>&#149; </span>"&Part($Items,8,";"),

    "<span style='color:yellow'>&#149; </span>"&Part($Items,9,";"),

    "<span style='color:green'>&#149; </span>"&Part($Items,10,";"))



    ------------------------------
    Meredith Moore
    ------------------------------
  • ben_simon's avatar
    ben_simon
    Community Manager

    Hi Bhargavi, thanks for posting your question here. Doesn't look like anyone from the Community has answered this question yet so let me see if I can find an answer for you. 



    ------------------------------
    Ben Simon
    ------------------------------
  • Unfortunately, you're not going to be able to use the UL and LI tags without also using some additional styling for the list like "list-style-image" for this. This is still not exactly what you're asking for (since it would mean one image for the whole list), so you'd probably have to do something like what Meridith showed. Her's is probably going to be the easiest if you always have a set number of options, but there are really a lot of different ways to approach this.



    ------------------------------
    Blake Harrison
    bharrison@datablender.io
    /
    ------------------------------