Difference between ( ViewData,TempData, ViewBag,Session) in asp.net mvc c# Hindi/Urdu | M-Tech Sol

M-Tech Sol
M-Tech Sol
4.9 هزار بار بازدید - 5 سال پیش - In this MVC ( Model
In this MVC ( Model view controller) video we will try to understand what is the difference between viewdata,viewbag,tempdata and session.This is an interesting MVC interview question and below is a textual answer for the same.
#mvctutorial #aspdotnetmvc5tutorial #MVC #ViewData #ViewBag #TempData
#default
#index
Temp data: - Helps to maintain data when you move from one controller to other controller or from one action to other action. In other words when you redirect, "tempdata" helps to maintain data between those redirects. It internally uses session variables.

View data: - Helps to maintain data when you move from controller to view.

View Bag: - It's a dynamic wrapper around view data. When you use "Viewbag" type casting is not required.
Difference between ( ViewData,TempData, ViewBag,Session) in asp.net mvc c# Hindi/Urdu | M-Tech Sol
5 سال پیش در تاریخ 1398/11/05 منتشر شده است.
4,951 بـار بازدید شده
... بیشتر