How could I convert data from string to long in c#

前端 未结 9 2129
慢半拍i
慢半拍i 2021-02-02 04:45

How could i convert data from string to long in C#?

I have data

String strValue[i] =\"1100.25\";

now i want it in

long         


        
9条回答
  •  伪装坚强ぢ
    2021-02-02 05:15

    You can also do using Int64.TryParse Method. It will return '0' if their is any string value but did not generate an error.

    Int64 l1;
    
    Int64.TryParse(strValue, out l1);
    

提交回复
热议问题