[mapguide-users] selectionXml - 1.time fast..then very slow...ZoomToView
farah at egovernments.org
Fri Nov 24 03:53:13 EST 2006
I am having a similar problem.
1.I do a query on a temporary layer and select a feature in it,
programmatically and then zoom to it with the help of setSelectionXml. This
2. I then clear the selection before performing a new query on the temporary
source and then try to do the same as step 1.
3. However, the application hangs when I try to update the temporary feature
source with the new features.
4. This doesn't happen if I don't do SetSelectionXml. So I am guessing that
by selecting a feature in the temporary layer, the feature source is some
how getting locked. So the next time I try to update it, it hangs.
5. I tried to delete the feature source and layer every time I perform a new
search and create it again. However, when I try to delete the feature
source, it throws a file IO Exception. This error does not happen if no
selection had been made previously!
Any one has any pointers? :-)
From: Maciej Skorczewski [mailto:maciej.skorczewski at procad.pl]
Sent: Friday, November 24, 2006 1:40 PM
To: users at mapguide.osgeo.org
Subject: [mapguide-users] selectionXml - 1.time fast..then very
i use (in php) this code to make xml of selected object...it works creat
when i use it first time(it is very fast)...then when i clik another
search results(streets and home)- so i use this script one more time -
my browser (FF and IE) stop working on 10-20 sec. user can't make any
action... why it is so? hove can i reload selectionXml (it is xml file )
what is faster? use pomQuery and selectionXml
ZoomToView(x, y, scale, refresh) ?
$pomQuery->SetFilter("NRBUDP_ID = '$nrbudp_id' and
$pomResId = new
$featureReader = $featureService->SelectFeatures($pomResId,
$layer = $map->GetLayers()->GetItem('Nrbudp');
$selection = new MgSelection($map);
$selection->AddFeatures($layer, $featureReader, 0);
$selectionXml = $selection->ToXml();
echo "selectionXml = '$selectionXml';\n
i call in <body onload="OnPageLoad()">
To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
For additional commands, e-mail: users-help at mapguide.osgeo.org
More information about the Mapguide-users