How to use viewbag in @Html.ActionLink

@Html.ActionLink with Viewbag

Viewbag inside @Html.ActionLink

You must need casting check following solution
@Html.ActionLink((string)ViewBag.Name, null)

About the Author

avatar