[Users] vector search difficulty with grid selection model
Robert Buckley
robertdbuckley at yahoo.com
Fri Jul 22 14:33:41 CEST 2011
Hi,
I have a search function in my app which follows this method...
1. enter search string in textbox
2. press search button -> which executes the search action in a form
3. the search layer (vector) is added to the map and tree and the feature
results to a gridpanel
4. click on dataset in grid -> the grid selectionmodel hightlights the dataset,
and zooms to the selected feature extent.
The search works great the first time, but after the search is complete, I would
like to remove the search layer from the map, close the gridpanel and continue
using the app without the vector layer in the map. If I don´t remove the search
layer, the vector layer stays on top of other layers meaning that the wms
getFeatureInfo can´t be called.
if I call map.removeLayer(searchlayer)....the layer is removed, but all
subsequent searches are not highlighted from the grid selection model.
Therefore I want to remove the layer in the map and the tree and somehow reset
the selection model in the grid so that future search results can be added again
and hightlighted in the grid´s selection model.
If you want to test it the url is here.
http://maps.zgb.de/www/eeg/search.html
The code is written ( and badly commented) in the html source.
any help or hints would be great,
yours,
rob
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.geoext.org/pipermail/users/attachments/20110722/1834c9fb/attachment.htm
More information about the Users
mailing list