Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Save value with request lifespan in asp.net

Is there a way to store a value that only is valid during the current request in asp.net on the server side. You have the Session where you can set values, you have the Cache where you can set values but you can only read values from the Request. Is there a way to write to the Request or is there other methods to do this?

like image 275
Andreas Avatar asked Apr 22 '11 09:04

Andreas


1 Answers

You can use HttpContext.Items. Here's an example which might help you.

like image 143
Jason Evans Avatar answered Oct 24 '22 16:10

Jason Evans