@Html.DropDownListFor(model => model.Contant.KEYWORD_NAME, ViewData["KEYWORD_NAME"] as IEnumerable, "Select Company Name", new { @class = "form-control" })
i use this way to pass value from view to contoller
@if (Model != null)
{
@Html.PagedListPager(Model.Items,page => Url.Action("search", new { page, search = Request.QueryString["search"] , KEYWORD = ViewData["KEYWORD_NAME"].ToString()}),
new PagedListRenderOptions()
{
Display = PagedListDisplayMode.IfNeeded,
DisplayPageCountAndCurrentLocation = true
,
DisplayItemSliceAndTotal = true
})
}
but in the contoller
in the URL broswer the KEYWORD vlue not null
public ActionResult search(int? page, string search, String KEYWORD)
the value of KEYWORD set to be "NULL " in the URL broswer the KEYWORD vlue not null

Arvind KushwahaRank #685 · 3.5K reputationPosted Sep 28, 2020, 8:02 PM EDT
Darshan ShahRank #1,135 · 1.6K reputationPosted Sep 29, 2020, 1:39 AM EDT
Mageshwaran RRank #411 · 6.1K reputationPosted Oct 6, 2020, 7:30 AM EDT