Posts

Showing posts from 2010

Session Management Asp.Net

Please do comment if you find this infromation contradictory. We should always have a centralized location to manage all the session variables in our application. This way, it is really very easy for all the programmers working on the application to get to know about Session Information. This session information can be reused whereever needed. It's not a problem to store "objects" (as opposed to value-types like int) into Session. You could even say it's better to store objects than value-types, because those value-types need "boxing" and "unboxing". To achieve this purpose, we have used hashtables to be saved in a session. Every module can have its own hashtable to group all the common session information. The key/value pair of the hash can be exposed through public properties. For instance, below is the complete code of Session Management Class for only one variable in a hashtable. Sample VB.Net Code 1: Public Shared Property NHPActive

The virtual path maps to another application, which is not allowed

Image
During the development we came across this issue, which wasted a lot of our precious time. So I decided to share its solution with everyone. We have Project and Sub-Project Structure i.e. we have a root project and several sub-projects. The ROOT Project is entitled as TEMS8 and all other subprojects have been configured as per the image below. (Click on the image for large size) Now after setting up everything on a new Machine, we came across the Error as The virtual path maps to another application, which is not allowed Finally after investigation, we figured out that we have created multiple virtual directories which mainly causes the issue. For instance, we have another virtual directory created for DATADEF which is inside the virtual directory of TEMS8. So this was the main issue. The resolution was to remove the DATADEF Virtual Directory. Everything worked out perfectly, once we removed the inner virtual directory. We should not have something like this image below  W

Silverlight 4 - Getting Started in ASP.Net

The new technology - Silverlight ! All the forums and websites full of its importance and usage. We are still in the phase of decision as to how to integrate Silverlight in our exisiting ASP.Net Application. With confused mind, we are unable to make any profound decision. Did some postings on the web also, to acquire the ideas of exprienced people to get to know the solution. One idea is to completley transform the exisiting application to SL, which is out of the question. Second idea is to find out the areas which we can replace with the SL Controls. We are still working on that. The main area would be to write a communication layer between the Asp.Net Current Application and the new Silverlight Application. WCF is the preferred way ! Will update on this blog about the work. Do comment, what do you think about SL and integration of it in Asp.Net