Custom CSS class in HTML Component of UiPath Task Form


Is there any way to add custom css class or custom css to the HTML component in Task Form. For example, In task form if I have taken the HTML Component control and have added <img src={{data.MyImage}} width=100 /> in the contents. Now if I have to apply some custom css class to img tag to make it re-sizable then how I can do that?

Though I am taking an example of the img tag here but actually I wants to know if we can attach css class to any tags in Task Form.

Is it possible while creating a task?

There is a field Class for the HTML component for the Create Form activity. Would it be useful?

For what @loginerror said you would need to define class for css in mentioned element and write below attributes you need and values. But there is easiest way to achieve it. You can add image the same way using Label element instead of HTML and define CSS just directly in it. Like this:


Hi. Could you share a sample xaml please ?

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.

Hi @SudhakarAs92,
The screenshot from above explains everything.

1 Like