Coming from an Classic ASP background I'm pretty cautious about placing objects into Session.
Would it be a bad idea for me to store an object of type Dictionary into Session within .NET?
Coming from an Classic ASP background I'm pretty cautious about placing objects into Session.
Would it be a bad idea for me to store an object of type Dictionary into Session within .NET?
You can put anything into Session... You just have to make sure not too much data is put into Session as this takes up server resources. This is something that will not be visible when testing your site at first, only when you deploy it and a lot of users start using it, as every user has its own Session object on the server.
Well, you won't have some of the issues that you would have with ASP. .net is not STA COM, so the thread affinity problems that you had with ASP are not going to hurt you (unless you try to store an STA COM object in the session, or in your dictionary).
Do be careful about concurrent access, though. If it is possible that multiple threads could access the dictionary (do to asynchronous page code, or maybe AJAX calls), then you will need to apply appropriate locking to the dictionary.
The big picture issues aren't really different than classic ASP (though I confess I didn't think about the differences that JMarsch raised). The answer depends on numerous factors: