ASP.NET: Highlight menu item of current page
<p>I've been trying to find an easy way of highlighting the current selected menu item of an asp.net menu (so the user knows which page they are on), but no matter what I have tried I can't get it to work. In my markup I have:</p>

<pre><code>&lt;asp:Menu ID="NavigationMenu" runat="server" CssClass="menu" EnableViewState="false" IncludeStyleBlock="false" Orientation="Horizontal" StaticSelectedStyle-ForeColor="#99CCFF" DynamicSelectedStyle-ForeColor="#99CCFF"&gt;
    &lt;Items&gt;
        &lt;asp:MenuItem NavigateUrl="~/Default.aspx" Text="Operations"/&gt;
        &lt;asp:MenuItem NavigateUrl="~/Analysis.aspx" Text="Analysis"/&gt;
        &lt;asp:MenuItem NavigateUrl="~/Dashboard.aspx" Text="Dashboard"/&gt;
        &lt;asp:MenuItem NavigateUrl="~/Flashboard.aspx" Text="Flashboard"/&gt;
        &lt;asp:MenuItem NavigateUrl="~/Spacequest.aspx" Text="SQ OBP"/&gt;
    &lt;/Items&gt;
&lt;/asp:Menu&gt;
</code></pre>

<p>And in the server side Page_Load function:</p>

<pre><code>((Menu)Master.FindControl("NavigationMenu")).Items[0].Selected = true;
</code></pre>

<p>But this does not work. I tried using a sitemap (even though a sitemap is not what I want to use) and that hasn't worked either. Any ideas?</p>
