I have tried to pass data from one Action to another in the same Controller.But always it is coming as null
Action1
ViewData["page"] = pageData;
Action2
var pageData = ViewData["page"];//Always Null
I have following requirement.
- Hit page and call Action1
- For same browser session store pageData in ViewData
- There will be one button on the page which will call Action2
- use ViewData["page"] to get pageData value which we have assign in Action1
Could anyone please help me to achieve this ?
Thanks