怎样把string类型的数字转化为int类型的
比如:
string value=“12”;
动作
int count=value;

解决方案 »

  1.   

    count = java.lang.Integer.parseInt(value);
      

  2.   

    agree with loulou82(南京以外不考虑~) 
      

  3.   

    count = Integer.parseInt(value);
    这样也行的~~~~~~~~~~
      

  4.   

    基本数据类型的容器都有相似的函数,就是parse后面的名字不同,作用是一样的
      

  5.   

    string value="12";
    int count=Integer.parseInt(value);
      

  6.   

    请问以下数据类型之间用什么函数进行转化???  
    String    转      int  
    int       转      String  
    String    转      long  
    long      转      String  
    String    转      double  
    double    转      String  
    ---------------------------------------------------------------  
     
    1.String.valueOf(int型数据);  
    2.Integer.parseInt(String型数据);  
    以下的跟上面差不多,只要把类型改为相应的就可以了.  
    ---------------------------------------------------------------  
     
    用函数转,不就这么转吗