title: C# ReadLine Variable String to Int
body: <p>I have a statement and then the user has to enter a key.<br>
  If they enter one they do one thing and another, another thing.</p>
  
  <p>From my Readline I have the problem where  </p>
  
  <blockquote>
    <p>"error CS0029: Cannot implicitly convert type 'int' to 'string'".</p>
  </blockquote>
  
  <p>What's the problem with this because I think I have:</p>
  
  <pre><code>choice = Convert.ToInt32(Console.ReadLine());
  </code></pre>
  
  <p><strong>EDIT</strong> </p>
  
  <p>So now I have used Steve's answer (below)</p>
  
  <p>This throws up this error message:</p>
  
  <blockquote>
    <p>CS0029: Cannot implicitly convert type 'int' to 'bool'</p>
  </blockquote>
  
  <p>And for this line I think:</p>
  
  <pre><code>case 1:
    // action for choice == 1
    if(choice = 1|2)
       Console.WriteLine("Choice {0} Selected",choice);
    break;
  </code></pre>