|
POST
|
I am unclear, are you having an issue syncing or saving any new feature? In the thread title and description you mention sync issue, but this post makes it look like the issue is trying to save a new feature into an offline geodatabase. Also are you using the geaodatabase downloaded from the sample service, or do you have your own service? I do not think the issue is with Editor Tracking because that exception is thrown when you try to set that attribute value, not on save.
... View more
04-27-2018
08:48 AM
|
0
|
6
|
3426
|
|
POST
|
I assume that you're passing IRuntimeControls to your view-model, and from there the view-model accesses the MapView? If that's the case, then your view-model is directly accessing a component of the view. I would argue this picks nits. The MapView is an object implemented on a class. No where in the application is there any knowledge of the implementation of IRuntimeControls, only that this interface exposes the MapView. A class is implemented that is added to a container, the rest of the application has no knowledge of how it is implemented. In the example you posted the Controller exposes the MapView. This is really no different and in the same way we don't now how that object was exposed. Just so happens in the example the MapView is tied to the controller using a Dependency Property instead of exposed from the UserControl that contains the MapView control. In my application I could do the same with the IRuntimeControl implementation and nothing in the rest of the application changes. Just for yucks, I did this. In an application that is over 100,000 lines of code based on some quick testing of the places I know the MapView is used in the application nothing broke. but if you're actually making the interface be required by the view-model via dependency injection, then the design is a further step removed from MVVM by imposing requirements on the view in order to use the view-model I do not know what that means, " imposing requirements on the view in order to use the view-model." There is no requirement on the view, there is a class that implements an interface that exposes the MapView class The interface is not required by the view model, however, when the MapView is needed the interface can be injected (I'll avoid the conversation on whether MEF is truly DI). We have a modular application, not only do none of the ViewModels know anything about the implementation of the IRuntimeControls interface, they don't even know where this is implementation lives, just that there is an interface and that interface provides access to a class of type MapView and if they ask, it will be provided. To me the issue partially comes down to the GeoView/MapView providing so much functionality that there is almost no way to not share it across a large application. The example uses a lot of code to perform something that was done in about 5 lines in my application (sharing MapView). Also using event aggregation instead of using the approach of an event implemented on IdentifyController class all MapView events can be tied into and again, no view model has any knowledge or coupling to how these events are fired. Just my thinking
... View more
04-25-2018
02:45 PM
|
0
|
0
|
3878
|
|
POST
|
I've taken a different approach that I think works pretty clean. I have an interface with an accessor of the MapView public interface IRuntimeControls
{
MapView MapView { get; }
} I implement this interface in the code behind of the class with the MapView and assign the MapView to the accessor. Maybe this breaks some true purism of MVVM having code in the code behind. But from here I can use dependency injection and share this class anywhere in the application. [Export(typeof(MobileAppMapView))]
[Export(typeof(IRuntimeControls))]
[PartCreationPolicy(CreationPolicy.Shared)]
public partial class MobileAppMapView : IRuntimeControls
{
public MobileAppMapView()
{
InitializeComponent();
MapView = EsriMapView;
SharedGraphicsOverlay = new GraphicsOverlay();
MapView.GraphicsOverlays.Add(SharedGraphicsOverlay);
}
public MapView MapView { get; }
public GraphicsOverlay SharedGraphicsOverlay { get; }
} This is using MEF, but you could do same approach with Unity. The first line: [Export(typeof(MobileAppMapView))] Is actually a necessity of using Prism regions for the UI composition, not with sharing the IRuntimeControls implementation across the project. Now all I need to do is import (MEF construct) the IRuntimeControls in any ViewModel the MapView object is needed.
... View more
04-25-2018
10:58 AM
|
0
|
3
|
3878
|
|
POST
|
GeometryEngine.Project Method (Geometry, SpatialReference)
... View more
04-24-2018
03:50 PM
|
1
|
1
|
2196
|
|
POST
|
You cannot create an offline replica database in code. The database is always associated to a service and needs to initially be created from that service, either in Runtime code or directly from the ArcGIS Server Rest API [Create Replica—ArcGIS REST API: Services Directory | ArcGIS for Developers ] (the Runtime is basically a wrapper that simplifies making the API calls). Once you have this initial offline database it can then be shared. This type of approach is known as a pre-planned workflow. Once you have this offline replica the process of adding features is basically identical to adding features to a service, except the source of the table is a GeodatabaseFeatureTable instead of a ServiceFeatureTable. This sample goes through opening a offline database and adding a feature Geodatabase transactions—ArcGIS Runtime SDK for .NET Samples | ArcGIS for Developers This links gives an overview of the different patterns and some links to more detailed information Create an offline layer—ArcGIS Runtime SDK for .NET (WPF) | ArcGIS for Developers There is a FeatureCollection table which would allow you to create a table and load features into it. This is an in memory object, so can really only be as a way to store data and add to a map for a given session. There is not a way to create a database that you could store this. FeatureCollectionTable Class
... View more
04-22-2018
11:37 AM
|
0
|
1
|
3493
|
|
POST
|
Have you worked through all the samples. The development team has put together a great set of sample code on-line and you can download the entire sample code from github. Sample Code—ArcGIS Runtime SDK for .NET Samples | ArcGIS for Developers Here is an example of creating an offline geodatabase Generate geodatabase—ArcGIS Runtime SDK for .NET Samples | ArcGIS for Developers and edit and sync Edit and sync features—ArcGIS Runtime SDK for .NET Samples | ArcGIS for Developers
... View more
04-21-2018
07:36 AM
|
0
|
4
|
3493
|
|
POST
|
It depends on what you are trying to do with this offline feature. Do you just want something you can persist offline? Or are you trying to create features that you want to send back to your enterprise geaodatabase
... View more
04-20-2018
07:59 AM
|
1
|
6
|
3493
|
|
POST
|
I don't know the answer to the question, but we have had the behavior you expect with vector tile packages.
... View more
04-19-2018
08:45 AM
|
2
|
1
|
4372
|
|
POST
|
We have noticed that when a FeatureLayer has a DefinitionExpression assigned and a feature gets synced from the server the display does not honor the DefinitionExpression. As example. A FeatureLayer.DefinitionExpression = "STATUS = 'Active'". When the STATUS value is changed at the server to something other than Active the attribute update does sync across as expected and the STATUS field is changed in the offline database. However, the feature is still visible even though it no longer meets the DefinitionExpression. If the application is closed and re-opened the feature is no longer visible as expected. We have tried moving the map, thinking maybe a redraw would refresh the layer but this does not work either. Is there a way to reapply the DefinitionExpression. I was going to try to toggle the expression off then back on but that seems more of a hack then I want to do. Thanks
... View more
03-22-2018
08:12 AM
|
0
|
4
|
1764
|
|
POST
|
I have gone and written a tool that makes the direct Rest API calls to create and then download the replica. The download performance difference is significant. Using a replica that is 166,640 KB. The API directly it takes 4:48 to generate and download the replica. The tool using direct Rest calls takes 2:19 As I can put logging into the custom tool, it shows ~2:15 to generate the replica on the server (I check every 15 seconds). Based on that that means the API takes 2:29 seconds more to download the replica than just making a direct call using the HttpsClient:GetStreamSync with the result Url. That is 38x longer on a file around 165 MB. On the network we are deploying the difference is even more significant than seen on our testing environment. This is using .net for WPF 100.2.
... View more
03-06-2018
04:46 PM
|
0
|
0
|
2905
|
|
POST
|
Common problems and solutions—Portal for ArcGIS (10.6) | ArcGIS Enterprise
... View more
01-31-2018
07:26 AM
|
1
|
1
|
1437
|
|
POST
|
After some further testing and debugging I believe this is because the tile package is in a local projection not Web Mercator like the online basemaps. I am setting up a vector tile map in the Web Mercator to confirm
... View more
01-18-2018
09:02 AM
|
0
|
1
|
1533
|
|
POST
|
We have a vector tile package stored on disk and loaded into our map. The behavior I am seeing is that if we load this layer along with a ArcGISTiledLayer the vector tile layer loads and display fine. However, if the ArcGISVectorTiledLayer is loaded with a map that already contains an ArcGISVectorTiledLayer that second layer will not display. I can see it is in the map, it just is not visible. The behavior is the same if the layer on disk is loaded first or the online layer is added first, whichever layer is added first will display, the second will not. Is this expected behavior? I find it odd that it is not possible to have multiple vector tile layers in the same map. Thanks -Joe Note: This testing has always been one layer loaded from a service and the other from a vector tile package
... View more
01-18-2018
07:39 AM
|
0
|
2
|
1844
|
|
POST
|
RenderTargetBitmap bitmap = new RenderTargetBitmap((int)mapView.ActualWidth, (int)mapView.ActualHeight, 96, 96, PixelFormats.Pbgra32);
bitmap.Render(mapView);
using (Stream s = File.Create(outputfile))
{
BitmapEncoder encoder = new PngBitmapEncoder();
encoder.Frames.Add(BitmapFrame.Create(bitmap));
encoder.Save(s);
}
... View more
01-16-2018
04:23 PM
|
0
|
1
|
6211
|
|
POST
|
It's based on the units of the spatial reference of the geometry
... View more
01-16-2018
04:12 PM
|
0
|
0
|
973
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 05-11-2026 09:07 AM | |
| 1 | 10-23-2025 12:16 PM | |
| 1 | 10-19-2022 01:08 PM | |
| 1 | 09-03-2025 09:25 AM | |
| 1 | 04-16-2025 12:37 PM |
| Online Status |
Offline
|
| Date Last Visited |
06-23-2026
12:26 PM
|