<html>
<head>
</head>
<body>
Hi Listers,<br>
<br>
doing a querybypoint the zoom to the queried polygon is doing well, but the
information is wrong. It gives the wrong result. Here's the code:<br>
<br>
Thanks a lot<br>
<br>
<br>
Peter <br>
<br>
<br>
<i>&nbsp;$queryresult = @$map -&gt; queryByPoint ($querypoint, MS_SINGLE, -1);<br>
&nbsp;<br>
&nbsp; <br>
&nbsp; if ($queryresult == MS_SUCCESS) {<br>
&nbsp;<br>
&nbsp;&nbsp;&nbsp; /* Bei einem Erfolg: Ergebnisse aus dem gew&uuml;nschten Layer holen*/<br>
&nbsp;&nbsp;&nbsp; $resultlayer = $map -&gt; getLayerByName ('objekte');<br>
<br>
/* Uns interessiert nur das erste (i.e. nullte) Resultat */<br>
&nbsp;&nbsp;&nbsp; $theresult = $resultlayer -&gt; getResult (0);<br>
&nbsp;&nbsp;&nbsp; $shapefile = ms_newShapefileObj ('<a class="moz-txt-link-freetext" href="C:\Programme\Apache">C:\Programme\Apache</a> Group\Apache\htdocs\immogis3w\code\data\objekte',
-1);<br>
&nbsp;&nbsp;&nbsp; $resultshape = $shapefile -&gt; getShape ($theresult -&gt; shapeindex);<br>
&nbsp;&nbsp;&nbsp; $resultbounds = $resultshape -&gt; bounds; &nbsp;</i><br>
&nbsp;&nbsp; &nbsp;<br>
&nbsp;&nbsp; &nbsp;<br>
&nbsp; &nbsp;<br>
&nbsp;&nbsp;&nbsp; /* Karte auf diese Extents zoomen */<br>
&nbsp;&nbsp;&nbsp; $map -&gt; setExtent ($resultbounds -&gt; minx-80, $resultbounds -&gt;
miny-80,$resultbounds -&gt; maxx+80, $resultbounds -&gt; maxy+80); <b>= CORRECT
ZOOM!!!</b><br>
&nbsp;&nbsp;&nbsp; $resultlayer = $map -&gt; getLayerByName ('objekte');<br>
&nbsp;&nbsp;&nbsp; $numresults = $resultlayer -&gt; getNumResults ();<br>
&nbsp;&nbsp;&nbsp; $theresult = $resultlayer -&gt; getResult (0);<br>
&nbsp;&nbsp;&nbsp; $resultclass = $resultlayer -&gt; getClass (0);<br>
&nbsp; &nbsp;<br>
&nbsp;&nbsp;&nbsp; $dbasefile = dbase_open (<a class="moz-txt-link-rfc2396E" href="C:\Programme\ApacheGroup\Apache\htdocs\immogis3w\code\data\objekte.dbf">"C:\Programme\Apache Group\Apache\htdocs\immogis3w\code\data\objekte.dbf"</a>,
0);<br>
<i>&nbsp;&nbsp;&nbsp; $dbrecord = dbase_get_record_with_names ($dbasefile, $theresult -&gt;
shapeindex);<br>
&nbsp;&nbsp;&nbsp; $Dummy = $dbrecord['ID'];<br>
&nbsp;&nbsp;&nbsp; printf ("%f&lt;br&gt;", $Dummy); &nbsp;</i><b>= WRONG RESULT!!!</b><br>
<br>
<br>
<br>
</body>
</html>