Can anyone pls suggest some solution for below question?
I have a data in the excel with the column A, where the values may start with alphabets or numerical.
How to check the starting character is alphabet or numerical
If it starts with alphabet i need to enter the data in text field, if its a number the we need to enter in exam Regno field
Please le me know if anyone has solution.
find some initial samples:
@ppr Can you please share the sequence
Another apporach is to work with Regex and group names:
where we can formulate following:
new Regex("(?<isDigit>^\d)|(?<isLetter>^[A-Za-z])").Match("1234").Groups.Cast(Of Group).Skip(1).Where(Function (g) g.Success).Select(Function (g).Name).toArray
same within the Query syntax
(From g in new Regex("(?<isDigit>^\d)|(?<isLetter>^[A-Za-z])").Match("1234").Groups.Cast(Of Group).Skip(1)
Select n = g.Name).toArray
which can be optimized and dynamized by using variables
You can use the function “first()”, “IsNumeric()”, “IsLetter” or “IsDigit”.
The result is always true or false.
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.