![]() |
||||
|
|
||||
[maplab-users] problem with setexpression()Martin Kiuru Martin.Kiuru@Elion.eeMon, 1 Mar 2004 16:10:47 +0200
|
||||
Hi,
I am trying to customize maplab-generated application. I need to find
one of the shapes on layer, zoom to it and hilite it. Zoom works fine
using $oMapNavigator->zoomScale(), but I have some problems with
hiliting. My idea was to use setexpression() to display polygon in
different color, but seems I do something wrong...
Here is the part of code from main application:
$oParcelLayer->open();
$oShape = $oParcelLayer->getShape(
$oResult->tileindex,$oResult->shapeindex );
$oExtents = $oShape->bounds;
$oShape->free();
$class=$oParcelLayer->getclass(0);
$class->setExpression($szParcelNumber);
$oParcelLayer->close();
I tried different syntax in setexpression() but without success...
And the layer definition from .map :
LAYER
NAME "KATASTER"
STATUS ON
TYPE POLYGON
TILEINDEX "kataster"
TILEITEM "location"
CLASSITEM "TUNNUS"
UNITS METERS
SIZEUNITS PIXELS
MAXSCALE 20000
TOLERANCE 0
TOLERANCEUNITS PIXELS
TRANSPARENCY 20
CLASS
NAME "TUNNUS"
EXPRESSION ""
TEMPLATE "ttt_query.html"
STYLE
SYMBOL 0
COLOR 255 0 0
OUTLINECOLOR 255 50 50
SIZE 1
MINSIZE 1
MAXSIZE 100
END
END
CLASS
NAME "OTHER"
TEMPLATE "ttt_query.html"
STYLE
SYMBOL 0
COLOR 204 255 255
OUTLINECOLOR 102 102 255
SIZE 1
MINSIZE 1
MAXSIZE 100
END
END
END
It seems that setexpression() do nothing... Can you help me to my bug ?
Thanks in advice
Martin.
This archive was generated by Pipermail. |
MapTools.org -- Hosted by DM Solutions Group |