Raja.G
(Mr.RPABot)
1
Hi Team,
I have one datattable i want to identify if double number found in particular column, This is always one row only
If found print yes found or print no
Double value example: "0.00 or 123.99 , 138.22, 129.55 , … " it will come in “cc” column if any of the double value found should print yes.
Please help me anyone for this.

Regards,
Raja G
lrtetala
(Lakshman Reddy)
2
Hi @Raja.G
Try this
isDoubleFound = dt.AsEnumerable().Any(Function(row) Double.TryParse(row("cc").ToString(), Nothing))
isDoubleFound variable datatype : Boolean
Input:

Regards,
1 Like
rlgandu
(Rajyalakshmi Gandu)
3
@Raja.G
isDoubleFound=dt.AsEnumerable().Any(Function(row) Double.TryParse(row("cc").ToString, New Double()))
isDoubleFound is boolean
if:isDoubleFound=True
Log Message :"Yes"
1 Like
vrdabberu
(Varunraj Dabberu)
4
Hi @Raja.G
Try this syntax:
result = If(dt.AsEnumerable().Any(Function(row) Double.TryParse(row("ccc").ToString(), Nothing)), "Yes", "No")
result is of DataType System.String
Regards
1 Like
Raja.G
(Mr.RPABot)
5
Hi @lrtetala /@rlgandu ,
Thanks, Working as expected.
Regards,
Raja G
1 Like
system
(system)
Closed
6
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.