|
POST
|
Hi, If you're porting your application from MapPoint to ArcGIS you might be interested in one of several ESRI .NET SDKs: Desktop WPF applications: http://resourcesbeta.arcgis.com/en/help/runtime-wpf/concepts/index.html#//017000000031000000 Web SilverLight applications: http://resourcesbeta.arcgis.com/en/webapis/silverlight-api/community/ Windows Phone: http://resourcesbeta.arcgis.com/en/help/windows-phone/sdk/concepts/index.html#//011v00000004000000 For serving up your spatial data from your backend database (assumed to be SQL server) you'll also be interested in ArcGIS Server (http://resourcesbeta.arcgis.com/en/help/main/10.1/index.html#/What_is_ArcGIS_for_Server/01540000037p000000/). There is also a lightweight Spatial Data Server for SQL Server included with "ArcGIS for Server Basic 10.1": http://resourcesbeta.arcgis.com/en/help/main/10.1/index.html#/What_is_ArcGIS_Spatial_Data_Server/01sq00000005000000/. Cheers Mike
... View more
01-12-2012
12:21 AM
|
0
|
0
|
775
|
|
POST
|
Hi, Standalone GDB tables can be included in Map Packages by adding them to your ArcMap document and sharing the map as a Map Package. You will however, need at least one feature class in the map in order for the map package to be valid. This feature class does not need to contain any features. From there, you start a LocalMapService using that MPK and then at Beta 2 you will need to use the FeatureLayer class to interact with (query/edit) the table. Since Beta 2 we have modified the ArcGISLocalFeatureLayer to also support standalone tables. Note - to work with standalone tables you must have the FeatureLayer in Snapshot mode (or selection only). OnDemand mode does not work with FeatureLayers based on standalone tables because it uses the map extent geometry to request query the service. Currently the HTML pages for the local server REST directory do not list the table, although it is available via the JSON e.g.: http://localhost.:50000/RxFdMP/arcgi...eServer?f=json http://localhost.:50000/RxFdMP/arcgi...pServer?f=json Cheers Mike
... View more
01-12-2012
12:09 AM
|
0
|
0
|
1643
|
|
POST
|
Hi, Standalone GDB tables can be included in Map Packages by adding them to your ArcMap document and sharing the map as a Map Package. You will however, need at least one feature class in the map in order for the map package to be valid. This feature class does not need to contain any features. From there, you start a LocalMapService using that MPK and then at Beta 2 you will need to use the FeatureLayer class to interact with (query/edit) the table. Since Beta 2 we have modified the ArcGISLocalFeatureLayer to also support standalone tables. Note - to work with standalone tables you must have the FeatureLayer in Snapshot mode (or selection only). OnDemand mode does not work with FeatureLayers based on standalone tables because it uses the map extent geometry to request query the service. Currently the HTML pages for the local server REST directory do not list the table, although it is available via the JSON e.g.: http://localhost.:50000/RxFdMP/arcgis/rest/services/tableediting/FeatureServer?f=json http://localhost.:50000/RxFdMP/arcgis/rest/services/tableediting/MapServer?f=json Cheers Mike
... View more
01-12-2012
12:05 AM
|
0
|
0
|
750
|
|
POST
|
Hi, The ComboBoxes are actually just populated in XAML (although there are obviously other, more elegant ways to achieve this): <Window x:Class="DynamicLayersDemo.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:esri="http://schemas.esri.com/arcgis/client/2009"
Title="ArcGIS Runtime SDK for WPF" Height="350" Width="525" WindowState="Maximized">
<Grid>
<esri:Map x:Name="MapControl" Background="LightGray">
</esri:Map>
<Grid HorizontalAlignment="Left" VerticalAlignment="Top" Margin="0,15,15,0" >
<Rectangle Fill="#77919191" Stroke="Gray" RadiusX="10" RadiusY="10" Margin="0,0,0,5" >
<Rectangle.Effect>
<DropShadowEffect/>
</Rectangle.Effect>
</Rectangle>
<Rectangle Fill="#FFFFFFFF" Stroke="DarkGray" RadiusX="5" RadiusY="5" Margin="10,10,10,15" />
<StackPanel Orientation="Vertical" Margin="20,20,20,20" HorizontalAlignment="Left" >
<TextBlock Text="Dynamic Layers Demo" HorizontalAlignment="Center" FontWeight="Bold" Margin="5,0,5,5" FontSize="18"/>
<TextBlock x:Name="InformationTextBlock" Text="Choose a new feature class and color ramp from the list below:"
Width="200" TextAlignment="Left" TextWrapping="Wrap" Margin="5,0,5,5" FontSize="16"/>
<ComboBox x:Name="NutsLevelsComboBox" SelectedIndex="0" Margin="5,0,5,5" FontSize="16">
<ComboBoxItem>NUTS0 (country level)</ComboBoxItem>
<ComboBoxItem>NUTS1 (3-7m people)</ComboBoxItem>
<ComboBoxItem>NUTS2 (0.8-3m people)</ComboBoxItem>
<ComboBoxItem>NUTS3 (0.15-0.8m people)</ComboBoxItem>
</ComboBox>
<ComboBox x:Name="colorComboBox" SelectedIndex="0" Margin="5,0,5,5" FontSize="16">
<ComboBoxItem>Yellow to Red</ComboBoxItem>
<ComboBoxItem>Green to Blue</ComboBoxItem>
</ComboBox>
<Button x:Name="UpdateMapButton" Click="UpdateMapButton_Click" Margin="5,0,5,5" FontSize="16">Update Map</Button>
</StackPanel>
</Grid>
</Grid>
</Window> Regarding the European Population Density Map Package - I simply created a new Map Package (with support for the ArcGIS Runtime) from the data you can download on ArcGIS.com: http://www.arcgis.com/home/item.html?id=cf3c8303e85748b5bc097cdbb5d39c31 Cheers Mike
... View more
01-11-2012
11:32 PM
|
0
|
0
|
2679
|
|
POST
|
Hi, Apologies for the misunderstanding in the original answer. When responding to the question in that post (http://forums.arcgis.com/threads/46471-Exposing-Feature-Class-from-(file)-GDB-into-WPF-app-as-Feature-Layer)... what would be the best way to expose a feature class which is stored in a (file) geodatabase in a WPF ESRI Map Control as a Feature Layer using ArcGIS Runtime. Currently we are using a empty map file (.mxd), add a reference to the feature class and save it as a new map file (.mxd), convert the .mxd to a map package with runtime support (.mpk) and then consume it as a LocalArcGISFeatureLayer. Would you agree that this is the best and preferred ESRI way? ... I did not realize that you were referring to an automated process. The process you outline is correct if undertaken as a manual process in ArcGIS for Desktop. Currently, the Package Map GP tool is not supported in the ArcGIS Runtime because it is considered an authoring tool. The process could be automated within ArcGIS for Desktop via .NET or Python. However, I believe the new ArcGIS Runtime Beta 2 dynamic layers functionality may allow you to achieve your goal. This enables you to entirely change the contents of an ArcGISLocalDynamicMapServiceLayer or ArcGISDynamicMapServiceLayer at runtime without the need for republishing an MPK. When using the ArcGIS Runtime local server with an MPK, you would register a Geodatabase or folder workspace with the LocalMapService and set the EnableDynamicLayers property to true prior to starting the service. Then, following the code example in http://forums.arcgis.com/threads/46471-Exposing-Feature-Class-from-(file)-GDB-into-WPF-app-as-Feature-Layer, you can add/remove featureclasses as required as if you were modifying the underlying MPK. However, this is all managed by the client API and so in reality the MPK remains unchanged. This functionality gives you enormous flexibility when working with local map services. Please let us know if the dynamic layers functionality will not enable you to achieve your desired workflow and we'll do some further investigation on this. Cheers Mike
... View more
01-11-2012
11:26 PM
|
0
|
0
|
1809
|
|
POST
|
Hi, Yes, that is the recommended route. You can choose to reference the File Geodatabase from the Map Package, in which case the MPK will refer to the original File GDB location or alternatively include the File GDB within the Map Package. UNC paths and/or mapped drives are also supported which can make referencing the File GDB easier. The new dynamic layers capability in Beta 2 also allows you to add new feature classes directly to a running LocalMapService. Unfortunately we didn't manage to include a sample for this in the new sample application but here is some code which should help you get started. This new dynamic layers functionality (also in ArcGIS for Server 10.1) operates on a per request basis - no changes are made to the underlying service and other users will not be affected. ## Default constructor ## public MainWindow() { InitializeComponent(); try { // get path to data relative to exe var dataFolder = System.IO.Path.GetFullPath(System.IO.Path.Combine( System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location), @"..\..\..\..")); var mapPackagePath = System.IO.Path.Combine(dataFolder, "Europe_Population_Density.mpk"); if (!File.Exists(mapPackagePath)) { MessageBox.Show("Map Package not found"); return; } _LocalMapService = new LocalMapService(System.IO.Path.Combine(dataFolder, "Europe_Population_Density.mpk")); // Make sure dynamic layers are enabled in this service _LocalMapService.EnableDynamicLayers = true; // Register workspaces to be used with this service. _LocalMapService.DynamicWorkspaces.Add(new WorkspaceInfo() { FactoryType = WorkspaceFactoryType.FileGDB, Id = "Europe_Population_DensityGDB", // a string to identify this workspace when repointing layers // Connection string must use "DATABASE=" to point to the fileGdb // API will automatically insert "DATABASE=" if it is not found in the connection string // API will resolve relative paths if they are used to refer to workspace // Workspaces are File GDBs, Folders (for Shapefiles) or Enterprise Geodatabases. ConnectionString = "DATABASE=" + System.IO.Path.Combine(dataFolder, "Europe_Population_Density.gdb"), }); _LocalMapService.StartAsync((mapService) => { var layer = new ArcGISLocalDynamicMapServiceLayer(_LocalMapService); layer.ImageFormat = ArcGISDynamicMapServiceLayer.RestImageFormat.PNG32; layer.InitializationFailed += (s, ex) => { MessageBox.Show("Failed to init layer: " + layer.InitializationFailure.ToString()); }; layer.Initialized += (s, ex) => { if (layer.InitializationFailure == null) _layer = layer; //UpdateMapButton_Click(null, null); }; MapControl.Layers.Add(layer); }); } catch (Exception ex) { var msg = ex.Message; } } ## Button Click event ## private void UpdateMapButton_Click(object sender, RoutedEventArgs e) { selectedItem = ((System.Windows.Controls.ComboBoxItem)FeatureclassComboBox.SelectedItem); string fcName = selectedItem.Content.ToString().Split(new Char[] { ' ' })[0]; // The following code will get the dynamic layer info collection from the layer (service) // and update the first item with a new DynamicLayerInfo object to change the data // source of an existing feature layer within the service. Alternatively you can create a // brand new DynamicLayerInfoCollection and begin adding new DynamicLayerInfos to this // collection. Doing this will effectively remove the existing layers and display only the new // feature layers defined. var layers = _layer.CreateDynamicLayerInfosFromLayerInfos(); layers[0] = new DynamicLayerInfo() { ID = 0, Source = new LayerDataSource() { DataSource = new TableDataSource() { DataSourceName = fcName, WorkspaceID = "Europe_Population_DensityGDB" } } }; _layer.DynamicLayerInfos = layers; LayerDrawingOptions layerDrawOpt = new LayerDrawingOptions(); layerDrawOpt.LayerID = 0; layerDrawOpt.Renderer = GetClassBreaksRenderer("POP_DENSIT"); _layer.LayerDrawingOptions = new LayerDrawingOptionsCollection() { layerDrawOpt }; _layer.Refresh(); } ## Get Class Breaks Renderer ## The code above uses another couple of methods to create a Class Breaks Renderer which is used for displaying the data thematically: private ClassBreaksRenderer GetClassBreaksRenderer(string attributeField) { ClassBreaksRenderer classBreaksRenderer = new ClassBreaksRenderer() { Attribute = attributeField }; Symbol baseSymbol = GetSimpleFillSymbol(Colors.LightGray, Colors.LightGray, 1); GenerateDataClassesTask generateDataClassesTask = new GenerateDataClassesTask(_LocalMapService.UrlMapService + "/0"); GenerateDataClassesParameters generateDataClassesParameters = new GenerateDataClassesParameters() { ClassificationDefinition = new ClassBreaksDefinition() { BaseSymbol = baseSymbol, ClassificationField = attributeField, ColorRamp = new ColorRamp() { Algorithm = Algorithm.HSVAlgorithm, From = _FromColor, To = _ToColor }, BreakCount = 6, ClassificationMethod = ClassificationMethod.NaturalBreaks, }, }; try { GenerateDataClassesResult generateDataClassesResult = generateDataClassesTask.Execute(generateDataClassesParameters); classBreaksRenderer = generateDataClassesResult.Renderer as ClassBreaksRenderer; } catch (Exception exception) { MessageBox.Show("Error: " + exception.Message); } return classBreaksRenderer; } private SimpleFillSymbol GetSimpleFillSymbol(Color fillColor, Color borderColor, double borderThickness) { SimpleFillSymbol fillSymbol = new SimpleFillSymbol() { BorderBrush = new SolidColorBrush(borderColor) {Opacity =0.75 }, BorderThickness = borderThickness, Fill = new SolidColorBrush(fillColor) }; return fillSymbol; } In the code above _FromColor and _ToColor are just class members from the System.Windows.Media namespace and in some other code in this example are updateable via a combobox. Color _FromColor = Colors.Yellow; Color _ToColor = Colors.Red; I hope that should get you started with dynamic layers. Cheers Mike
... View more
12-22-2011
11:13 PM
|
0
|
0
|
2679
|
|
POST
|
Hi, That post details the Beta 2 workaround for administering your developer install. However, we don't encourage you to edit the json file directly. Alternatively, you should use the Deployment Tool to create a "debug deployment" - which means use the debug options dialog in the Deployment Tool to enable these settings then use the LocalServer.InstallDirectory property to pickup the debug local server. We are planning to provide a utility to administer the developer settings in a future release. Cheers Mike
... View more
12-22-2011
10:51 PM
|
0
|
0
|
1398
|
|
POST
|
Hi, That's the workaround for administering your developer install in Beta 2. However, we don't encourage you to edit the json file directly. Alternatively, you should use the Deployment Tool to create a "debug deployment" - which means use the debug options dialog in the Deployment Tool to enable these settings then use the LocalServer.InstallDirectory property to pickup the debug local server. We are planning to provide a utility to administer the developer settings in a future release. Cheers Mike
... View more
12-22-2011
10:49 PM
|
0
|
0
|
589
|
|
POST
|
Hi, That error message may mean that the TPK file itself has some compression. Many changes have been made to the TPK reading since Beta 1. However - ArcGIS 10.1 Beta 2 includes the functionality for extracting a TPK from an existing cached service. There are server admin GP tools (e.g. http://<SERVERNAME>:6080/arcgis/rest/services/System/CachingTools/GPServer/Export%20Cache) or this can be done in ArcMap/ArcCatalog - connect to an ArcGIS Server, right click on the map service and choose Manage Cache > Export Cache. But the workflow is most likely to involve using the Extract Cache tool in the Server Tools toolbox inside your own GP Model and publishing that GP Model as a service which you then consume via the API of the ArcGIS Runtime SDK for WPF. Cheers Mike
... View more
12-15-2011
04:36 AM
|
0
|
0
|
2379
|
|
POST
|
OK, I've had success generating map packages by building a model, and it works well. What I'm now having a hard time with is generating tile packages. Using server tools->Caching I can generate a Tiling Scheme, no problem. But if I try to Create/Export into a tile package, it always has an input service as required input, which I don't have. If I use File->Share As->Tile Package then I have the option of either a Tiling Scheme or a Map service. So is it possible to do this as a model? Andrew Purkis Hi, There are plans for a specific GP tool to create Tile Packages - but I believe it didn't make it into Beta 2 of ArcGIS for Desktop. That means, for the time being, you'll need to use the GUI from the "File > Share As..." menu. Cheers Mike
... View more
12-14-2011
06:02 AM
|
0
|
0
|
1981
|
|
POST
|
Hi, We'll investigate this and get back to you. Cheers Mike
... View more
12-13-2011
10:40 PM
|
0
|
0
|
686
|
|
POST
|
Hi, Unfortunately, we didn't manage to include any specific printing support in the API in Beta 2. You might want to take a look at this SL/WPF sample from Dominique Broux: http://www.arcgis.com/home/item.html?id=e361c2cc69784fcba34358d0458f66e3. Cheers Mike
... View more
12-13-2011
10:39 PM
|
0
|
0
|
1781
|
|
POST
|
For Engine, Desktop, and Server it is possible to customize the system using low level (fined grained) ArcObject APIs. Is there any similar provision for ArcGIS Runtime? Essentially, do you have an extension mechanism which runs in disconnected environments which allows a non-ESRI developer to access ArcObjects? Richard, The ArcGIS Runtime SDKs do not allow you to access ArcObjects in a disconnected environment. The current point for extensibility is Geoprocessing, including support for Python scripts. However, on the longer term roadmap, we are considering an extensibility framework for the ArcGIS Runtime ideally based on an "add-in" model which would continue to support the simple Xcopy-style deployment story. Cheers Mike
... View more
12-12-2011
11:25 PM
|
0
|
0
|
1766
|
|
POST
|
Hi, Currently, with ArcGIS 10.0 for fully offline work your main option is ArcGIS Engine and the WindowsFormsHost control. Or alternatively, if your solution is going to be intermittently connected and you want an edit synchronization framework you could look at ArcGIS Mobile and again the WindowsFormsHost control. As per Richard's post, we're working on a full WPF solution called the "ArcGIS Runtime SDK for WPF". This SDK is designed to work with both online services from ArcGIS Server (on-premise/cloud) and offline local content for mapping, search/query, editing, geocoding, and geoprocessing. This will enable you to create WPF applications which are completely disconnected but also you can write applications which are partially/intermittently connected or fully connected too. there are some introductory videos you can watch here: http://video.arcgis.com/tag/639/arcgis-runtime We're just about to release Beta 2 of the ArcGIS Runtime SDK for WPF so now is a great time to join the beta community if you're not already signed up. You can start here: http://beta.esri.com/community/. The first version of this product will be shipping around the same timeframe as ArcGIS 10.1 next year. Cheers Mike
... View more
12-12-2011
12:04 AM
|
0
|
0
|
1766
|
|
POST
|
Hi, The ArcGISLocalFeatureLayer & FeatureLayer classes are for providing an additional level of interaction with the data - such as MapTips, or editing. Specifying the symbology via the ArcGIS Runtime WPF API in the past has only been possible with feature layers but at Beta 2 (available very soon) the ArcGIS Runtime SDK for WPF will also support overriding the default symbology within dynamic map service layers. However to achieve the MapTips you're after, you'll still need to use a feature layer. You may be able to use a combination of the two though - a dynamic map service layer for overall display of the points (and override the symbology in this layer too) and a feature layer set to Mode=SelectionOnly for interaction. This will require the user to perform a selection first, but you could experiment with the options/modes to see if it serves your purpose. Cheers Mike
... View more
12-09-2011
07:09 AM
|
0
|
0
|
1126
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 04-14-2026 05:04 AM | |
| 1 | 02-20-2024 07:02 AM | |
| 1 | 01-19-2026 06:44 AM | |
| 1 | 12-10-2025 07:16 AM | |
| 1 | 11-21-2025 08:12 AM |
| Online Status |
Offline
|
| Date Last Visited |
3 weeks ago
|