How to validate a text field is not empty (or contains a value) using UiPath?

hi… I’ve just started learning UiPath. As part of a process, I have to verify that a partcular field of a web form is never empty and contains a value provided by the customer. How can I use UiPath to verify this?

Thanks in advance!

1 Like

Hi

Welcome to uipath forum

Hope the below steps would help you resolve this

  1. Use a GET ATTRIBUTE activity and indicate on that field in web page and get the output of the attribute aaname or innerText or text

Here you go on how to use that Get Attribute activity

  1. Save the output as string variable named Strinput

  2. Then use a IF activity like this

String.IsNullOrEmpty(Strinput.ToString.Trim)

If true it means it’s blank

Cheers @SR29

1 Like

Hi @SR29

You can use Get Text Activity - Indicate on the Text in the web form you need

Store the value in the Output Variable (GetValue)

Use If Activity

Condition - GetValue <> “” Or GetValue = Value provided by the customer

Hope it will helps.
Regards
Gokul

1 Like

Thank you, Palaniyappan!

1 Like

Thank you Gokul!

Fine

Is there any further queries on this topic

@SR29

No further queries… Thank you.

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