Skip to main content
Best answer by stewart.burchell

It's not ideal but you can use a Unicode value to insert the relevant symbol into the 'Placeholder' attribute of a text box:

char(128269) & " Search Course by name or id"

It's a bit cartoony which is why it's not ideal imo.

10 replies

stewart.burchell
January 18, 2023

It's not ideal but you can use a Unicode value to insert the relevant symbol into the 'Placeholder' attribute of a text box:

char(128269) & " Search Course by name or id"

It's a bit cartoony which is why it's not ideal imo.

natashan0002
January 18, 2023

Thats what i want But the search icon is coming in blue. 

agamb0001
January 18, 2023

[mention:085d3bc5d05849eb930c6b472a918645:e9ed411860ed4f2ba0265705b8793d05],

You probably cannot place that icon inside the text field, (unless you try something what Stewart has suggested above)

I believe the nearest you could do is to put the icon and text field side by side

something like this 

a!sideBySideLayout(
  alignVertical: "MIDDLE",
  items: {
    a!sideBySideItem(
      width: "MINIMIZE",
      item: a!richTextDisplayField(
        value: a!richTextIcon(
          icon: "search",
          color: "SECONDARY",
          size: "MEDIUM"
        )
      )
    ),
    a!sideBySideItem(
      item: a!textField(
        placeholder: "Search course by name or id"
      )
    )
  }
)

Hope it helps ! 

stewart.burchell
January 18, 2023

That looks WAY better imo!!