I need to check that if the variable type is int, then i need to change the format to “{0:0.0}”, how we can do this via query or function.
Can you please explain more about your use case? It would be better if you could share some sample data also.
Thanks
@agathiyanv ,
You can ue String.Isnumeric to check if it is int or not!
Hi @agathiyanv
You can get the Variable type Like this
YourVariable.GetType
Uss If condition and check it
Regards
Gokul
HI @agathiyanv
Try like this
if(Input.GetType.Tostring.Equals("System.Int32"),Cdec(Input.ToString).ToString("#.00"),"Not An integer")
Hope this Helps
Regards
Sudharsan
can we remove the else part?
Yes if you don’t need anything you simply give a empty quotes there like “” @agathiyanv
1 Like