Quantcast
Viewing all articles
Browse latest Browse all 4757

Set ViewData using JavaScript or jQuery in ASP.Net MVC

Here Mudassar Ahmed Khan has explained with an example, how to set ViewData using JavaScript or jQuery in ASP.Net MVC Razor. ViewData is created on Server Side of the Web application and hence it is not possible to directly set it on Client Side using JavaScript or jQuery. Thus, only possible way is to set it by making an AJAX call to the Controller’s Action method using jQuery AJAX function in ASP.Net MVC Razor.

Viewing all articles
Browse latest Browse all 4757

Trending Articles