title: Showing help for a command-line utility
body: <p>I have a command-line utility that gets quite a bit of downloads from my site. I'm trying to show the usage when a user uses the /? or /help parameters. I have a function called ShowUsage() that has nicely formatted text on the parameters available.</p>
  
  <p>I see that ShowUsage() gets called fine from Visual Studio 2008, when I'm using the command-line parameters in the project properties. However the exe does not display the help text when run from the command-line. Here's a shortened version of ShowUsage():</p>
  
  <pre><code>private static void ShowUsage()
  {
      Console.WriteLine(Environment.NewLine);
      Console.WriteLine("Text File Splitter v1.4.1  released: December 14, 2008");
      Console.WriteLine("Copyright (C) 2007-2008 Hector Sosa, Jr");
      Console.WriteLine("http://www.systemwidgets.com");
      Console.WriteLine("");
  }
  </code></pre>
  
  <p>I tried a bunch of different things from my searches in Google, but none are working. I know this has to be something simple/easy, but for the life of me, I can't figure this one out.</p>
  
  <p><strong>EDIT:</strong></p>
  
  <p>The code that calls ShowUsage():</p>
  
  <pre><code>if (!Equals(cmdargs["help"], null) || !Equals(cmdargs["?"], null))
  {
      ShowUsage();
  }
  </code></pre>
  
  <p>I have a class that parses the parameters into the cmdargs array. I confirmed that the parameters are in the array. It's something inside ShowUsage() that is preventing from showing the text.</p>
  
  <p>I'm going to try the debug trick, and see what I find.</p>
  
  <p>I'm not using Console.Out anywhere.</p>
  
  <p>d03boy - Just personal preference. It makes the text less cluttered onscreen, at least to me.</p>
  
  <p><strong>EDIT #2</strong></p>
  
  <p>Ok, some more information... I'm running VS2008 in Vista Ultimate 64 bit. I just check the project properties and it is set to "Windows Application." This utility is 32 bit.</p>
  
  <p>I'm going to experiment with creating a separate project in the solution that is a true console program, as some of you have advised.</p>