Begin Form helper class help to POST the form content to action method.
Syntax of Begin Form Helper method
Syntax of Begin Form Helper method
@using (Html.BeginForm ("AddDetails",
"Home", FormMethod.Post, new { enctype =
"multipart/form-data" }))
{
-----Form Content-----
}
Output
the following HTML
<form action="Home/AddDetails"
method=POST>
Action Link
Action Link helper method is used to link to an action method.
Syntax of Action Link Helper method
Action Link helper method is used to link to an action method.
Syntax of Action Link Helper method
@Html.ActionLink ("Show list",
"Index", "Country")
It links to 'Index' method in 'CountryController'.
Output the following HTML
Output the following HTML
<a href="Country/Index">Show
list</a>
It 's excellent posting
ReplyDeleteDot Net Online Training Hyderabad