Which code segment should you use?

You create an ASP.NET MVC 2 Web application. You implement a single project area in the
application. In the Areas folder, you add a subfolder named Test. You add files named
TestController.cs and Details.aspx to the appropriate subfolders. You register the area’s route,
setting the route name to test_default and the area name to test. You create a view named Info.aspx

that is outside the test are A. You need to add a link to Info.aspx that points to Details. aspx. Which
code segment should you use?

You create an ASP.NET MVC 2 Web application. You implement a single project area in the
application. In the Areas folder, you add a subfolder named Test. You add files named
TestController.cs and Details.aspx to the appropriate subfolders. You register the area’s route,
setting the route name to test_default and the area name to test. You create a view named Info.aspx

that is outside the test are A. You need to add a link to Info.aspx that points to Details. aspx. Which
code segment should you use?

A.
<%= Html.RouteLink(“Test”, “test_default”, new {area = “test”}, null) %>

B.
<%= Html.ActionLink(“Test”, “Details”, “Test”, new {area = “test”}, null) %>

C.
<a href=”<%= Html.RouteLink(“Test”, “test_default”, new {area = “test”}, null)
%>”>Test</a>

D.
<a href=”<%= Html.ActionLink(“Test”, “Details”, “Test”, new {area = “test”}, null) %>”>Test</a>



Leave a Reply 0

Your email address will not be published. Required fields are marked *