Hi Yale,
Thanks for replying.
1). I add a number of ShapeFileFeatureLayers according to what options a user has set. There is one for the postcode areas, one for towns, and one for postcode area centres. Is this wrong? Surely the map would throw an exception if I were not allowed more.
The two postcode-related areas come from the same file on disk, The towns layer comes from another file on disk. ZoomLevels are set that at the widest extent (seeing the whole country) onthe the first layer is visible.
I add the layer like this:
Map1.StaticOverlay.Layers.Add("kpiGroupLayer", kpiGroupLayer);
But even with one shape file it does not work. If I comment-out adding of the other layers it fails with 'Input string was not in a correct format' (that is, it draws that text on the map). Is it too much to ask for it to report which input string. what value, and what format is expected? Why does it hide this information?
2) I am not trying to fetch data from the same source. What I want to do is colour-code the regions on the map (from the shape file on disk) with data from the database. That is, the shape file has a column called 'COM_DIST' (for example), and I want to look up the value for which that should be colour-coded from a Dictionary which I have populated from the database. Therefore the reason I am looking into the source is to find the key value for the aforementioned dictionary given the id passed to me by the ..._CustomColumnFetch event.
3) If you mean the shape file - we have purchased this and I cannot upload it to this forum. I have uploaded up to a ShapeFile folder I have created on the FTP site you gave me access to.
I can load it into Map Suite Explorer with no problems reported. If I turn on the (i) feature and click on regions sometimes I get data back, but sometimes I get:
System.ArgumentOutOfRangeException
The decimal degree longitude value you provided was out of range.
Parameter name: fromLongitude
But does it say what the erroneous value was? No. Does it say what the range of valid values is? No. Does it report detailed info to the Windows event log? No.
Why haven't your developers taken the extra 30 seconds to augment the error with this kind of information. For example, this is what Sql Server reports if you try and create a row that's too big:
Creating or altering table 'T' failed because the minimum row size would be 16011, including 7 bytes of internal overhead. This exceeds the maximum allowable table row size of 8060 bytes.
I'm sure it would save a lot of time in the long run.
Anyway, thanks for your help
cheers
Matt