ThinkGeo.com    |     Documentation    |     Premium Support

Publishing the "CSharp HowDoISamples" to WIN2008 server

Hu Guys,


Just getting started, so probably a very stupid question but we are having problems getting things running on IIS7 on WIN2008 server.


We installed the WEB edition beta on a Vista box, ran the "HowDoISamples" locally without any problems on the local server.


We then used the publish option from VS2008, accepted all the defaults and shunted the project to our big server on the local intranet, publish went normally aprt from a problem with an img folder under themes not being copied, fixed that.


Hitting the default.aspx page on the big server results in the sample apps screen appearing, nothing missing apart from the map, the rest is as it should be.  The page reports an error :-


Line: 192


Char: 15


Error 'MultiMap' is undefined


Code: 0


URL 192.168.2.2/Samples/GettingStarted/DisplayASimpleMap.aspx


Can't seem to get beyond this.


Any thoughts on what this might be?


Regards


 


John



John, 
  
 Seems the HttpHandlers of WebEdition are not properly registered.  These HttpHandlers are critical for displaying the map. Please Check your site web.config file to make sure it contains the section below: 
  
 
<httpHandlers>
      <remove path="*.asmx" verb="*" />
      <add path="*.asmx" verb="*" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"
        validate="false" />
      <add path="*_AppService.axd" verb="*" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"
        validate="false" />
      <add path="ScriptResource.axd" verb="GET,HEAD" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"
        validate="false" />
      <add path="*_GeoResource.axd" verb="*" type="ThinkGeo.MapSuite.WebEdition.GeoResourceFactory" />

 
  
 You can just copy the web.config file from HowDoISamples if it doesn’t contain any special configuration. 
  
 Any more queries please let us know. 
  
 Ben 


Hi Ben,


Kind of thought it was something like that.  The lines you quoted were in the web.config file.


I added the _GeoResource.axd handler manually throught the IIS Manager Handler Mappings and everything works fine.


Thanks for the help.


John



Great!  
  
 Any more queries just let us know. 
  
 Ben

I have (I think) a similiar issue to this.  I am running Vista with IIS7.  I run your 2008 C# samples and they work great.  I change the Projects Web settings to 'Use Local IIS Web server' with a URL of localhost/CSharpHowDoISamples and now when I run the samples get; mapParser is undefined and MultiMap is undefined.


The reason that I tried the above is that the solution that I have created gets the same errors when I run it inside IIS 7.0  I am thinking that this is a configuraiton issue but have tried everything that I can think of.  Thanks so much for your help.



Okay, I read a bit more on this and if I add the



 


add name="ThinkGeo" path="*_GeoResource.axd" verb="*" type="ThinkGeo.MapSuite.WebEdition.GeoResourceFactory" 


It now works...



The following to the system.webserver handlers section



Tony,  
  
 Very glad you make it. Let us know for more queries. 
  
 Ben