|
POST
|
FeatureLayer (and QueryTask) support spatial filter through its Geometry property. Here's are few examples: FeatureLayer.Geometry http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#FeatureLayerFiltering
<esri:FeatureLayer ID="SpatialFilterFeatureLayer"
Url="http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Demographics/ESRI_Census_USA/MapServer/3"
Renderer="{StaticResource MySimplePolygonRenderer}">
<esri:FeatureLayer.Geometry>
<esri:Envelope XMin="-100" YMin="42" XMax="-95" YMax="47" >
<esri:Envelope.SpatialReference>
<esri:SpatialReference WKID="4326"/>
</esri:Envelope.SpatialReference>
</esri:Envelope>
</esri:FeatureLayer.Geometry>
</esri:FeatureLayer>
Query.Geometry http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#SpatialQuery
Query query = new ESRI.ArcGIS.Client.Tasks.Query();
// Specify fields to return from query
query.OutFields.AddRange(new string[] { "STATE_NAME", "SUB_REGION", "STATE_FIPS", "STATE_ABBR", "POP2000", "POP2007" });
query.Geometry = args.Geometry;
// Return geometry with result features
query.ReturnGeometry = true;
query.OutSpatialReference = MyMap.SpatialReference;
queryTask.ExecuteAsync(query);
... View more
01-18-2012
07:56 AM
|
0
|
0
|
1301
|
|
POST
|
You can also use IdentifyTask and InfoWindow. Use the following SDK samples for reference: http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#InfoWindowSimple http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#Identify
... View more
01-17-2012
03:07 PM
|
0
|
0
|
792
|
|
POST
|
I'd like to reproduce this bug, what version of ArcGISServer are you using? I have the following code, please let me know if it needs to be tweaked to get the same performance slowdown that you are experiencing. I will be testing it against latest and previous releases. Using the code below, I did not experience a slowdown between 2.1, 2.2. and latest. If you can share service and/or code, that would help us reproduce the bug and hopefully fix it. Thanks. What I've noticed is that there seems to be no difference in server response for ReturnGeometry=True and ReturnGeometry=False using sampleserver3. I just learned that this is a known server bug that is planned to be fixed in future releases.
xmlns:esri="http://schemas.esri.com/arcgis/client/2009">
<Grid x:Name="LayoutRoot" Background="White">
<esri:Map WrapAround="True" x:Name="MyMap">
<esri:ArcGISTiledMapServiceLayer ID="MyLayer"
Url="http://services.arcgisonline.com/ArcGIS/rest/services/ESRI_Imagery_World_2D/MapServer" />
<esri:GraphicsLayer ID="MyGraphicsLayer">
<esri:GraphicsLayer.Renderer>
<esri:SimpleRenderer>
<esri:SimpleRenderer.Symbol>
<esri:SimpleMarkerSymbol Color="Red" Size="15" Style="Circle"/>
</esri:SimpleRenderer.Symbol>
</esri:SimpleRenderer>
</esri:GraphicsLayer.Renderer>
</esri:GraphicsLayer>
</esri:Map>
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center">
<Button Content="Query" Click="Button_Click"/>
<CheckBox x:Name="ReturnGeom" IsChecked="False"/>
</StackPanel>
</Grid>
DateTime started;
private void Button_Click(object sender, RoutedEventArgs e)
{
var queryTask = new QueryTask("http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/Earthquakes/EarthquakesFromLastSevenDays/FeatureServer/0")
{
DisableClientCaching = true
};
var query = new Query() { ReturnGeometry = ReturnGeom.IsChecked.Value , Where = "1=1"};
queryTask.ExecuteCompleted += new EventHandler<QueryEventArgs>(queryTask_ExecuteCompleted);
started = DateTime.Now;
queryTask.ExecuteAsync(query);
}
void queryTask_ExecuteCompleted(object sender, QueryEventArgs e)
{
var elapsed = DateTime.Now.Subtract(started).TotalMilliseconds;
System.Diagnostics.Debug.WriteLine("Elapsed time (ms): {0}", elapsed);
(sender as QueryTask).ExecuteCompleted -= queryTask_ExecuteCompleted;
var l = MyMap.Layers["MyGraphicsLayer"] as GraphicsLayer;
if (e.FeatureSet != null)
{
foreach (var f in e.FeatureSet.Features)
l.Graphics.Add(f);
}
}
... View more
01-17-2012
02:56 PM
|
0
|
0
|
742
|
|
POST
|
Jeff, can you share your code? I would like to reproduce the bug so we could fix it in future versions. I'm not able to repro with the following code.
<Grid x:Name="LayoutRoot" Background="White">
<esri:Map x:Name="myMap" WrapAround="True">
<esri:ArcGISTiledMapServiceLayer
ID="baseMap"
Url="http://services.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer" />
</esri:Map>
</Grid>
public MainPage()
{
InitializeComponent();
QueryTask queryTask = new QueryTask("http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/Fire/Sheep/MapServer/0");
Query query = new Query() { Where = "1=1", ReturnGeometry = true, OutSpatialReference = myMap.SpatialReference };
queryTask.ExecuteCompleted += (s, e) =>
{
var l = new GraphicsLayer();
foreach (var r in e.FeatureSet.Features)
l.Graphics.Add(r);
System.Diagnostics.Debug.WriteLine(l.FullExtent);
};
queryTask.ExecuteAsync(query);
}
... View more
01-13-2012
01:11 PM
|
0
|
0
|
1358
|
|
POST
|
Yes that's correct. FeatureDataForm will generate a control base on the field type that your service defines. I think you need to create subtypes and attribute domains first http://help.arcgis.com/en/arcgisserver/10.0/help/arcgis_server_dotnet_help/index.html#//0093000000r0000000.
... View more
01-13-2012
12:53 PM
|
0
|
0
|
710
|
|
POST
|
FeatureDataForm use ComboBox for coded-value domain and feature types. You can see this in the following SDK sample: http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#ToolkitFeatureDataForm Feature service defines "req_type" as Type ID Field and "status" has a domain associated to it.
... View more
01-13-2012
11:23 AM
|
0
|
0
|
710
|
|
POST
|
The problem seems to be that your map is WKID=3857 and you want to zoom to an extent with WKID=4326. Since you already have the resolution, maybe you should call ZoomToResolution, there is an overload for including MapPoint http://help.arcgis.com/en/webapi/silverlight/apiref/ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.Map~ZoomToResolution%28Double,MapPoint%29.html
... View more
01-12-2012
02:59 PM
|
0
|
0
|
1949
|
|
POST
|
The FlareClusterer as seen in this SDK sample has few properties you can set: http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#SimpleClusterer. You can provide a custom clusterer with your own template like in this sample: http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#CustomClusterer.
... View more
01-12-2012
02:50 PM
|
0
|
0
|
916
|
|
POST
|
If you moving the point location is interactive, you can use Editor.EditVertices command or EditorWidget.EditVertices http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#ToolkitEditorWidget. After you click on the EditVertices button, you can start dragging the point feature to its new location. EditGeometry only support polyline, polygon, envelope geometries. Thus, point geometries are handled separately as seen in this SDK sample http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#EditToolsGeometry.
private void MyMap_MouseMove(object sender, MouseEventArgs e)
{
if (selectedPointGraphic != null)
selectedPointGraphic.Geometry = MyMap.ScreenToMap(e.GetPosition(MyMap));
}
... View more
01-12-2012
02:47 PM
|
0
|
0
|
1022
|
|
POST
|
This seem related: http://forums.arcgis.com/threads/29244-HELP-Set-MapTip-on-Graphic-not-GraphicsLayer. You can probably use another UserControl and put the logic for adding HyperlinkButton on SizeChanged.
... View more
01-12-2012
06:40 AM
|
0
|
0
|
1944
|
|
POST
|
DataFormBorder.Visibility = Visibility.Visible FeatureDataForm.GraphicSource = change.Geometry FeatureDataForm.FeatureLayer = TryCast(change.Layer, FeatureLayer) FeatureDataForm.GraphicSource = change.Graphic Kindly remove the highlighted line.
... View more
01-12-2012
06:36 AM
|
0
|
0
|
3102
|
|
POST
|
It is by design that you are getting all attributes as response to the Identify request. You can simply ignore the attributes you don't need. In this SDK sample http://help.arcgis.com/en/webapi/silverlight/samples/start.htm#Identify you can update the following code:
<slData:DataGridTextColumn Binding="{Binding Path=Key}" FontWeight="Bold"/>
<slData:DataGridTextColumn Binding="{Binding Path=Value}"/>
to
<slData:DataGridTextColumn Binding="{Binding [ObjectID]}"/>
... View more
01-12-2012
06:33 AM
|
0
|
0
|
772
|
|
POST
|
Can you subscribe to FeatureLayer.EndSaveEdits and SaveEditsFailed event? Do you get any error? You can run Fiddler to see monitor the web requests. You are right that the code-behind snippet is not necessary, the buttons will activate on click because of the command binding. This code may also be the reason you are getting a cancel action. Activating a command (by click or code) will cancel previous command.
... View more
01-11-2012
01:36 PM
|
0
|
0
|
686
|
|
POST
|
You should be setting FeatureDataGrid.GraphicsLayer property, not its ItemsSource. You can probably use another GraphicsLayer to display the results from your database. You are right that FeatureDataGrid.Headers are dependent on FeatureLayer.Fields. However if you are using GraphicsLayer, the columns/headers will be dependent on graphic.Attributes. So if you find that using FeatureLayer is limiting, you can switch to using GraphicsLayer so you can add/remove to the graphic.Attributes and have FeatureDataGrid reflect this change.
... View more
01-11-2012
01:28 PM
|
0
|
0
|
548
|
|
POST
|
Here's some help doc on creating web maps from ArcGIS.com: http://help.arcgis.com/en/arcgisonline/help/index.html#//010q0000001n000000 Actually, the map contains 2 layers: ArcGISTiledMapServiceLayer (base map) and FeatureLayer (contains points from CSV). The webmap JSON http://www.arcgis.com/sharing/content/items/e64c82296b5a48acb0a7f18e3f556607/data?f=pjson includes popup information. In the help doc above, look at "Configuring pop-up windows" section as well.
... View more
01-11-2012
01:16 PM
|
0
|
0
|
556
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 07-10-2026 12:13 PM | |
| 1 | 09-11-2025 01:30 PM | |
| 1 | 06-06-2025 10:14 AM | |
| 1 | 03-17-2025 09:47 AM | |
| 1 | 07-24-2024 07:32 AM |
| Online Status |
Offline
|
| Date Last Visited |
07-13-2026
09:07 AM
|