Register  |  Login   Search
ThinkGeo - GPS Tracking and Mapping Solutions  |  Home  |  Cygnus Track  |  Developer Community
 
LivePerson Chat

Discussion Forums

The online community for users of Map Suite GIS components

SelectFeatures
Last Post 05-23-2007 04:15 AM by Clint. 1 Replies.
Printer Friendly
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
JosephUser is Offline
Level 2
Level 2
Posts:54

--
05-16-2007 09:25 AM
When I follow your example in SelectFeaturesModeApp.aspx/.cs and I click on the image the FeatureInfos is always null.

.aspx
< asp:ImageButton ID="ImageButton1" runat="server"
ImageUrl="./images/info.ico"
AlternateText="Identify"
CssClass="imgbtn"
Style="position: relative" OnClick="Lnkinfo_Click" />
< font face="Lucida Sans Unicode, Verdana" size="1">
< asp:linkbutton id="Lnkinfo" runat="server" onclick="Lnkinfo_Click">Identify</asp:linkbutton>< /font>


.cs
Created Map1 Events for SelectFeatures and SelectMapShapes

Button or Image click
protected void Lnkinfo_Click(object sender, EventArgs e)
{
Map1.Mode = Map.ModeType.SelectFeatures;
}
protected void Lnkinfo_Click(object sender, ImageClickEventArgs e)
{
Map1.Mode = Map.ModeType.SelectFeatures;
}

Select:
protected void Map1_SelectFeatures(FeatureInfo[] FeatureInfos)
{
//Get the Feature(s) selected from the Map
if (FeatureInfos != null)
{
mFeatureInfos = new FeatureInfo[FeatureInfos.Length];
Session["mFeatureInfos"] = FeatureInfos;
}

Update the listboxes with the feature Information.
UpdateInfoForm(FeatureInfos);
}


ClintUser is Offline
Level 1
Level 1
Posts:3

--
05-23-2007 04:15 AM
Please check to make sure you have the SelectFeatureMode property set to true on the layers that you want to raise the event for.

Code sampel below:

Layers[0].SelectFeatureMode = true;
You are not authorized to post a reply.

Active Forums 4.1