title: Since '{method}' returns void, a return keyword must not be followed by an object expression
body: <p>I'm trying to return a simple string from an XML file when you call a method after defining the location of the XML file. However, when I try to return, it says that "Since 'CareerDescription()' returns void, a return keyword must not be followed by an object expression". The word return is highlighted red and that's the message. Compiler will say "Method must have a return type". I do have the return type but it doesn't want to return... Here is the code:</p>
  
  <pre><code>    public CareerDescription(string CareerFile)
      {
          XmlDocument xmlDoc = new XmlDocument();
          xmlDoc.Load(CareerFile);
          string Description = xmlDoc.SelectSingleNode("Careers/CareerList/CareerDescription").InnerText;
          return Description;
      }
  </code></pre>
  
  <p>I also tried this to see if it was something wrong with the method I created, however I get the same exact error message....</p>
  
  <pre><code>    public TestMethod()
      {
          string test = "test";
          if (test == "test")
          {
              return test;
          }
      }
  </code></pre>
  
  <p>And this also gives the same message...</p>
  
  <pre><code>    public TestMethod()
      {
          string test = "test";
          return test;
      }
  </code></pre>
  
  <p>What am I doing wrong in the creation of my methods? I can't for the life of me figure it out...</p>