How to display month number on selecting month name
<p>I am having list of Months displayed in drop down on selecting particular month i would like to display the number of the month in a text box</p>

<p>For example if i select <code>January</code> i would like to display as <code>01</code> like wise for all the other too</p>

<p>This is the sample code i have written</p>

<pre><code>string mnthname="january";
int i=DateTime.ParseExact(mnthname, "MMMM", CultureInfo.CurrentCulture).Month;
</code></pre>
