Click here to Skip to main content
15,920,217 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more:
i have to navigate to another page according to the selection of dropdown . For example if i select india from my dropdown i want to navigate to index page. if i select russia the sample page.where and how I write code in mvc? am using razor in mvc
Posted
Updated 15-Jul-11 20:01pm
v5

1 solution

Hi,
You can write code in .cshtml file like this

@if (condition) { }



and

@if (!Request.IsAuthenticated)
{
<li>@Html.ActionLink("Register", "Create", "User")</li>
}
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900