7
Answers

How to save value in session in mvc razor page

suman goud

suman goud

8y
263
1
i want to save EmpID  in session, my view code
 
<a href="#@i.EmpID,new{[email protected]}" onclick="">@i.Name</a>
 
<input type='hidden' name="id" formmethod="post" value="@Session["id"][email protected]'" />
 
but EmpID is not saving in session , how to do this 
 

Answers (7)