Problem in getting Feature Data of Polygoan

Topics: SharpMap v0.9 / v1.x
Oct 19, 2010 at 7:35 AM

The map is made up of vector data having multiple polygons
when i click on the map to retrive data from the shp file i am able to get the data but instead of getting single row output for the polygon clicked i get multiple rows of data i.e. of the polgon i have clicked and of adjucient polygons. but i need to have the id of only the polygon i have clicked the code i am using is  ExecuteIntersectionQuery method.

Please Help me.....

Sandip Chakraborty

India

 

 



 

 

Coordinator
Oct 19, 2010 at 10:28 AM

Hello Sandip Chakraborty,

depending on your datasource sharpmap only tests for intersection of bounding boxes (e.g. Shapefile). If you need true intersection testing, you have to reference NetTopologySuite and perform the additional step described here.

Hth FObermaier

Oct 20, 2010 at 8:50 AM

Hi,

Thanks for the solution...and its work fine and i also able to Zoom the selected featurs with ZOOMTOBOX property. But again i want to click on another polygon with the current zoom state then the dataset return with empty data.

please help me...

Regards

Sandip Chakraborty

Oct 20, 2010 at 9:14 AM

Hi,

I have solved the problem. Is there any option where we can set  the OPACITY  and TRANSPARENCY   in Layer -> Style ->Fill property.

 

Coordinator
Oct 20, 2010 at 1:31 PM

You can set the alpha value for the fill color to achive transparency

Hth FObermaier

Oct 28, 2010 at 11:06 AM

Hi,

When i am using TrueIntersection of NetTopologySuite on Polygon type shape file its working fine, but when I want to click on  Line type layer its not working, its return empty result set.

please help me....

Regards

Sandip Chakraborty

 

 

Coordinator
Oct 28, 2010 at 12:47 PM
Edited Oct 28, 2010 at 12:50 PM

Hello sandipchk,

to hit the line with a click is a difficult task. Maybe you need to use a small rectangle to intersect with the linestring.

The MapImage/MapBox control do that by default. If you are using one of those, then maybe all you need to do is increase the grow factor.

May I point your attention to the newly added Project "SharpMap.SqlServerSpatialObjects". It can perform true intersection testing as well.

Hth FObermaier