I believe you need to refresh the map...

Martin

From: mapguide-users-boun...@lists.osgeo.org 
[mailto:mapguide-users-boun...@lists.osgeo.org] On Behalf Of 
ravinder.si...@birlasoft.com
Sent: Wednesday, February 25, 2009 6:57 AM
To: mapguide-users@lists.osgeo.org
Subject: [mapguide-users] Features Are Not Highlighted

Hi,

I have written the following code to select/highlight the features on the map.

        MgMap map = new MgMap(myConnection);
        map.Open("MyMap");
        MgFeatureQueryOptions queryOptions = new MgFeatureQueryOptions();
        queryOptions.SetFilter("ID<4");
        MgLayer layer = map.GetLayers().GetItem(0) as MgLayer;
        MgFeatureReader featureReader = layer.SelectFeatures(queryOptions);
        MgSelection selection = new MgSelection(map);
        selection.AddFeatures(layer, featureReader, 0);
        selectionXml = selection.ToXml();

The code runs perfectly. And in viewer it also shows that 2 Features Selected. 
But features are not highlighted on the map.
Please assist...

Thanks & Regards,
Ravinder

******************************************************************************************************************************

"This message and any attachments are solely for the intended recipient and may 
contain Birlasoft confidential or privileged information. If you are not the 
intended recipient,any disclosure,copying, use, or distribution of the 
information included in this message and any attachments is

prohibited. If you have received this communication in error, please notify us 
by reply e-mail(administra...@birlasoft.com) immediately and permanently delete 
this message and any attachments. Thank you."

******************************************************************************************************************************
_______________________________________________
mapguide-users mailing list
mapguide-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapguide-users

Reply via email to