title: SOAP client in .NET - references or examples?
body: <p><strong>Background:</strong></p>
  
  <p>I am creating a webservices site which will provide many types of simple services over SOAP and possibly other protocols too. The goal is to make it easy to do for example conversions, RSS parsing, spam checks and many other types of work. The site will be targeted mostly at beginner developers.</p>
  
  <p><strong>My Problem:</strong></p>
  
  <p>I have never developed any C#, or .NET for that matter. I did hack some VB6 many years ago but that's it. Now I need some <strong>examples of doing RPC calls over SOAP in C#</strong>. I have tried to search the web, and Stack Overflow, to find this but didn't find many resources, and I have no idea how to rank the resources (which are old? which are incorrect? etc).</p>
  
  <p>I have created a simple example service, which is called like this in PHP:</p>
  
  <pre><code>&lt;?php
  $client = new SoapClient('http://webservi.se/year'); //URL to the WSDL
  echo $client-&gt;getCurrentYear(); //This method returns an integer, called "year"
  ?&gt;
  </code></pre>
  
  <p>I now want to call this method as easily as possible in C#. All references and examples are very welcome. Where do I begin? Which classes/modules/whatever can I utilize?</p>
  
  <p>The solution does not have to involve SOAP at all if there are better communication frameworks (the back end is meant to be extensible), but note that the server side is implemented in PHP on Unix so proprietary solutions from Microsoft are out of the question on the server side.</p>
  
  <p>Note that I need this so I can write documentation possible for J. Random Web Developer to follow (even if they are on shared web hosting). I therefore think the best approach should be to do this in code only, but even other ways of doing this are of course welcome.</p>