We use MapInfo MapX mapping engine in our ASP.NET application. After server (Windows Server 2003 SP2) reinstallation we encountered a strange problem - web app hangs when accessing ActiveX instance.
For example:
MapXLib.Map _mapXMap =
(MapXLib.Map)HttpContext.Current.Server.CreateObject("MapX.Map.5");
_mapXMap.MapUnit = MapXLib.MapUnitConstants.miUnitKilometer; // application hangs here
However, the code
MapXLib.Map _mapXMap =
(MapXLib.Map)Activator.CreateInstance(Type.GetTypeFromProgID("MapX.Map.5"));
_mapXMap.MapUnit = MapXLib.MapUnitConstants.miUnitKilometer;
works fine within a standard windows application.
I think the problem is related to COM and ASP.NET, because the application worked fine before server reinstallation.