[mapserver-users] C# functon resultCacheMemberObj shapeindex ... Posible bug?

Paul james pauljame at gmail.com
Tue May 20 05:12:59 PDT 2008


I´m using Postgis...
My mapfile:

  MAP
 EXTENT -79.7892 -34.2426 -24.9958 6.11775
 FONTSET "fonts.txt"
 IMAGECOLOR 255 255 255
 IMAGETYPE png
 SYMBOLSET "symbols.sym"
 SIZE 400 200
 STATUS ON
 UNITS dd
 NAME "World"

 OUTPUTFORMAT
  NAME gif
  MIMETYPE image/png
  DRIVER gd/png
  EXTENSION png
  IMAGEMODE rgb
  TRANSPARENT FALSE
 END

 QUERYMAP
  COLOR 255 0 0
  SIZE -1 -1
  STATUS ON
  STYLE hilite
 END

 LAYER  #With string PK
  NAME city
  GROUP "GROUP1"
  TYPE POLYGON
  STATUS ON
  CONNECTIONTYPE POSTGIS
  CONNECTION "user=X password=x dbname=tblX host=localhost"
  DATA "geom from tblX USING UNIQUE idX USING SRID=4291"
  CLASS
   TEMPLATE "dummy"
   NAME "x"
   COLOR 255 255 185
   OUTLINECOLOR 110 110 110
  END
 END
END


On 5/19/08, Tamas Szekeres <szekerest at gmail.com> wrote:
>
> Hi,
>
> Which driver are you using, how the mapfile looks like?
>
>
> Tamas
>
>
> 2008/5/19 Paul james <pauljame at gmail.com>:
> > Hello guys...
> > I have a table with a character(11) PK...
> > When I trie to get the shapes with queryByRect, all results are with
> > shapeindex equal 0 (zero) ...
> > If I tried that with a table with a integer PK, everthing works perfect..
> > My code:
> >
> > layerObj _layer = mapObj.getLayerByName(__layer);
> > if (_layer.queryByRect(mapObj, _oGeo) == 0)
> > {
> >    for (int i = 0; i < _layer.getNumResults(); i++)
> >    {
> >     resultCacheMemberObj _result = _layer.getResult(i);
> >      //_result.shapeindex == 0
> >     shapeObj _obj = new shapeObj(-1); //dummy
> >    _layer.open();
> >    _layer.getShape(_obj, -1, _result.shapeindex);
> >   }
> > }
> >
> >
> >
> > Any solutions?
> >
> > []´s
> >
> > _______________________________________________
> > mapserver-users mailing list
> > mapserver-users at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
> >
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20080520/531c00ed/attachment.htm>


More information about the MapServer-users mailing list