title: webmethod: cannot implicity convert type string to int
body: <p>Hi with this code I get: cannot implicity convert type string to int.</p>
  
  <pre><code>        CalculateSumOfList.ServiceReference1.Service1SoapClient client = new CalculateSumOfList.ServiceReference1.Service1SoapClient();
          CalculateSumOfList.ServiceReference1.ArrayOfInt arrayOfInt = new CalculateSumOfList.ServiceReference1.ArrayOfInt();
          arrayOfInt.AddRange(listInt);
          int result = client.CalculateSum(arrayOfInt); //error here!
          label1.Text = Convert.ToString(result);
  </code></pre>
  
  <p>The webmethod I am calling is here:</p>
  
  <pre><code>namespace CalculateWebServiceSum
  {
      /// &lt;summary&gt;
      /// Summary description for Service1
      /// &lt;/summary&gt;
      [WebService(Namespace = "http://tempuri.org/")]
      [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
      [System.ComponentModel.ToolboxItem(false)]
      // To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. 
      // [System.Web.Script.Services.ScriptService]
      public class Service1 : System.Web.Services.WebService
      {
  
          [WebMethod]
          public string CalculateSum(List&lt;int&gt; listInt)
          {
              int[] sum = listInt.ToArray();
  
              return sum.ToString();
  
          }
      }
  }
  </code></pre>