|
POST
|
You can try the following code. I tweaked just the highlighted code from this SDK sample: http://resources.arcgis.com/en/help/silverlight-api/samples/start.htm#Find FindTask findTask = new FindTask("http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Specialty/ESRI_StatesCitiesRivers_USA/MapServer");
findTask.ExecuteCompleted += (a, b) =>
{
Dispatcher.BeginInvoke((Action)delegate
{
MessageBox.Show(string.Format("Result.Count: {0}", b.FindResults.Count));
});
};
FindParameters findParameters = new FindParameters();
findParameters.LayerIds.AddRange(new int[] { 0, 1, 2 });
findParameters.SearchFields.AddRange(new string[] { "CITY_NAME", "NAME", "SYSTEM", "STATE_ABBR", "STATE_NAME" });
findParameters.LayerDefinitions = new LayerDefinition[]
{
new LayerDefinition() { LayerID = 0, Definition = "STATE='California" },
new LayerDefinition() { LayerID = 2, Definition = "STATE='California" }
};
findParameters.SpatialReference =new SpatialReference(4326);
findParameters.SearchText = "River";
findTask.ExecuteAsync(findParameters);
... View more
07-13-2012
10:01 AM
|
0
|
0
|
583
|
|
POST
|
The DataTemplate is created for you based on the webmap PopupInfo. Unfortunately a MaxWidth/MaxHeight is set for image so it currently cannot exceed 235/145. If you are not using Webmap Popups, you can change the DataTemplate as you wish: http://resources.arcgis.com/en/help/silverlight-api/samples/start.htm#InfoWindowSimple For example: <DataTemplate x:Key="MyFeatureLayerInfoWindowTemplate"> <StackPanel> <TextBlock Text="{Binding [STATE_NAME]}" Foreground="Black" FontSize="12" /> <Image Source="http://2.bp.blogspot.com/-2TNxVSJ4J9E/TfYfd0ChiMI/AAAAAAAABcc/53CtYEptiBY/s1600/USA-flag.jpg" Height="300" Width="300"/> <Button Content="Close" Click="Button_Click"/> </StackPanel> </DataTemplate> private void Button_Click(object sender, RoutedEventArgs e) { MyInfoWindow.IsOpen = false; }
... View more
07-03-2012
12:28 PM
|
0
|
0
|
769
|
|
POST
|
Is Legend.LayerIDs property set? If yes, this needs to include the new layer ID's. If not, does your new GraphicsLayer have a renderer? You can try the following code:
<Grid x:Name="LayoutRoot">
<esri:Map x:Name="MyMap" WrapAround="True">
<esri:ArcGISTiledMapServiceLayer
Url="http://services.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer" />
</esri:Map>
<esri:Legend Map="{Binding ElementName=MyMap}"
LayerItemsMode="Tree"
VerticalAlignment="Top" HorizontalAlignment="Right" />
<Button VerticalAlignment="Top" HorizontalAlignment="Left" Content="Add Layer" Click="Button_Click"/>
</Grid>
private void Button_Click(object sender, RoutedEventArgs e)
{
var l = new GraphicsLayer() { ID = "MyLayer" };
l.Renderer = new SimpleRenderer()
{
Symbol = new SimpleMarkerSymbol()
{
Color = new SolidColorBrush(Colors.Blue),
Size = 20d,
Style = SimpleMarkerSymbol.SimpleMarkerStyle.Square
},
Label = "Locations"
};
l.Graphics.Add(new Graphic() { Geometry = new MapPoint(-140.9, 63.391, new SpatialReference(4326)) });
MyMap.Layers.Add(l);
}
... View more
07-03-2012
11:32 AM
|
0
|
0
|
528
|
|
POST
|
I think you can use the following code: private void KmlLayer_Initialized(object sender, EventArgs e) { var l = sender as KmlLayer; if (l.Graphics != null) { foreach (var g in l.Graphics) { if (g is Graphic) { (g as Graphic).MouseEnter += Graphic_MouseEnter; (g as Graphic).MouseLeave += Graphic_MouseLeave; } } } } void Graphic_MouseLeave(object sender, MouseEventArgs e) { this.Cursor = Cursors.Arrow; } void Graphic_MouseEnter(object sender, MouseEventArgs e) { this.Cursor = Cursors.Hand; }
... View more
07-03-2012
11:07 AM
|
0
|
0
|
929
|
|
POST
|
We have not exposed this from ArcGIS API for Silverlight. You could use the following documentation as resource: http://sampleserver3.arcgisonline.com/ArcGIS/SDK/REST/generatekml.html
... View more
07-03-2012
10:58 AM
|
0
|
0
|
625
|
|
POST
|
None of the layers show? What type of layers are on your map? Could you run Fiddler to see if there were any error message? Thanks.
... View more
07-03-2012
10:25 AM
|
0
|
0
|
787
|
|
POST
|
GdbVersion is a new property in FeatureLayer and QueryTask (also IdentifyTask and FindTask) in v3.0: http://resources.arcgis.com/en/help/silverlight-api/apiref/api_start.htm?ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.FeatureLayer~GdbVersion.html. This allows you to specify specific geodatabase version other than default.
... View more
07-03-2012
10:21 AM
|
0
|
0
|
1065
|
|
POST
|
By balloon image, do you mean callout window like InfoWindow? http://resources.arcgis.com/en/help/silverlight-api/samples/start.htm#InfoWindowSimple. You can change DataTemplate to include Image control instead that maybe has HyperlinkButton on top of it.
... View more
07-03-2012
10:09 AM
|
0
|
0
|
451
|
|
POST
|
I was able to repro with 10.1 server. Can you check to see if we have the same error message from Fiddler? <html> <head> <title> Error: Error parsing multi-part request</title> <link href="https://community.esri.com/arcgis/rest/static/main.css" rel="stylesheet" type="text/css"/> </head> <body> <table width="100%" class="userTable"> <tr> <td class="titlecell">ArcGIS REST Framework</td> </tr> </table> <table width="100%" class="navTable"> <tr valign="top"> <td class="breadcrumbs"> <a href="https://community.esri.com/arcgis/rest/services">Home</a> </td> </tr> </table> <div class="cbody"> <br/> <br/> <b>Error: </b>Error parsing multi-part request<br/> <b>Code: </b>500<br/><br/> <div style="color:#ff6666"> </div> </div> </body> </html> If you are using ArcGIS Server v10.1, I believe this is where UploadTask becomes useful.
... View more
07-03-2012
09:46 AM
|
0
|
0
|
2496
|
|
POST
|
You can go to the following resources: Silverlight website: http://www.silverlight.net/learn Tim Heuer's Getting Started with Silverlight development: http://timheuer.com/blog/articles/getting-started-with-silverlight-development.aspx Getting Started with ArcGIS API for Silverlight: http://resources.arcgis.com/en/help/silverlight-api/concepts/index.html#/Getting_started/016600000004000000/ Interactive SDK samples: http://resources.arcgis.com/en/help/silverlight-api/samples/start.htm
... View more
07-03-2012
09:24 AM
|
0
|
0
|
435
|
|
POST
|
Thank you for reporting this bug. I was able to reproduce with your sample. We'll try to fix this in future versions. For FeatureDataGrid source code from: http://esrisilverlight.codeplex.com/ and add a null check for featureLayer in Graphic_AttributeValueChanged() line# 467.
... View more
07-02-2012
06:07 PM
|
0
|
0
|
795
|
|
POST
|
You might want to use Silverlight or MSDN forum for these type of questions in the future. I'm not sure if this example is sufficient: http://stackoverflow.com/questions/8230438/download-file-from-absolute-uri-to-stream-to-savefiledialog
... View more
07-02-2012
05:53 PM
|
0
|
0
|
604
|
|
POST
|
You can configure pop-up on ArcGIS.com by following these steps: http://help.arcgis.com/en/arcgisonline/help/index.html#//010q0000004m000000
... View more
07-02-2012
05:46 PM
|
0
|
0
|
494
|
|
POST
|
The controls used in FeatureDataForm is created at runtime based on the field type. You can change the behavior by downloading the source code and updating GetControlFromType() http://esrisilverlight.codeplex.com/
... View more
07-02-2012
05:44 PM
|
0
|
0
|
492
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | a week ago | |
| 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 |
Monday
|