Showing posts with label ViewBag In MVC Application. Show all posts
Showing posts with label ViewBag In MVC Application. Show all posts

Sunday, 3 September 2017

ViewBag In MVC Application

In This Article, I would like to know you about the Use Of ViewBag In MVC Application.

Actually ViewBag is a dynamic property, which is used to pass data from Controller To Corresponding View.  And It Is The Wrapper Of ViewData i.e., ViewBag uses ViewData Internally  And ViewData Is Derived From Dictonary Class Called ViewDataDictionary. The Life Of ViewData Is Only Lies In Current Request,But If Redirection Occurs, Then It’s value becomes null. And It Does Not Require Typecasting. So It Is Slower Than ViewData.