[Gdal-dev] Using SetSpatialFilter() on MapInfo .tab files

Mir Hassan Ali mirhassanali at gmail.com
Wed Nov 8 05:01:14 EST 2006


Hi,

I am trying to set Spatial Filter on a MapInfo tab file (using the C#
wrapper for GDAL). I am working with Projected Coordinate System and want to
set the filter for the point defined by coordinates

393544.0 377079.0

I am using the following code to set the filter

layer.SetSpatialFilter(new Geometry(ogr.wkbUnknown , "POINT(393544.0
377079.0)", 0, null, null));
But after settign the filter I get feature count = 0 whereas it should be 2
for the particular point.
I am getting this pair of coordinates from a LLPG(Local land and property
gazetteer). Do I need to transform these coordinates in some way before
setting the filter or is there something else I am doing wrong?
Please will someone guide me regarding this problem.

Thanks and Kind Regards

Mir Hassan Ali
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20061108/23c7e5a7/attachment.html


More information about the Gdal-dev mailing list