Check the string is digit

How to check the given string is digit or not

@Sweety_Girl,

Check with this Regex("^\d$") using Regex operations, you can import a namespace System.Text.RegularExpressions to work with Regex.

1 Like

Hi @Sweety_Girl
Use System.Text.RegularExpressions.Regex.IsMatch(YourString,"[0-9]") this will give you a Boolean value.

1 Like

You have a inbuilt method to check if string is number or not.
IsNumeric(string)
returns true if string is a number else false.

Regards,
Karthik Byggari

3 Likes

To be very simple
You string is if str_input
Then a assign activity like this
Bool_numeric = IsNumeric(str_input.ToString)

Where bool_numeric is a variable of type Boolean
Cheers @Sweety_Girl

1 Like

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