POST
|
Hi, I have a problem with UniqueValueRenderer symbology. I have published a .mxd document to a ArcGIS Server as a feature service. I have defined the layer symbology in ArcMap. ArcMap has this Symbol Levels feature: I'm using it to define the drawing order of unique value symbols. Is there anyway to draw the symbols in the same defined order in the Runtime MapView using FeatureLayer and UniqueValueRenderer? Currently the features are drawn this way in ArcMap: and this way in the MapView of my application: I'm using version 10.2.7 of Runtime SDK for .NET, version 10.3.1 of ArcMap and version 10.22 of ArcGIS Server. Regards, Tuukka J
... View more
01-05-2017
07:19 AM
|
0
|
2
|
2486
|
POST
|
Hi, I have an application where user can edit polygon geometries by drawing a polyline. The tool works fine most of the time but sometimes the users are able to draw a polyline that gives the following exception when used to reshape a polygon: {System.Exception: Out of range : at RuntimeCoreNet.Interop.HandleException(Boolean retVal) at RuntimeCoreNet.CoreGeometryEngine.Reshape(ICoreGeometry geometry, CorePolyline reshaper, CoreSpatialReference sr) at Esri.ArcGISRuntime.Geometry.GeometryEngine.Reshape(Geometry geometry, Polyline reshaper) at ArcGISRuntime.Samples.DesktopViewer.MainWindow.ReshapeGeometry()} HResult = -2146233088 Currently I just handle the exception and notify the user but I was wondering what actually is causing that error because the application would accept the edit otherwise. I was able to reproduce this easily with following code:
private void ReshapeGeometry()
{
var segment = new LineSegment(571528.331418344, 7015935.19781517, 571522.829343446, 7015932.7313678);
var segment1 = new LineSegment(571522.829343446, 7015932.7313678, 571526.821556906, 7015958.60602131);
var segment2 = new LineSegment(571526.821556906, 7015958.60602131, 571539.179356696, 7015958.48119505);
var segment3 = new LineSegment(571539.179356696, 7015958.48119505, 571538.650188972, 7015936.78531834);
var polylinebuilder = new PolylineBuilder(new SpatialReference(3067));
polylinebuilder.AddPart(new List<Segment>() {segment, segment1, segment2, segment3});
var polyline = polylinebuilder.ToGeometry();
var polygonSegmentList = new List<Segment>();
polygonSegmentList.Add(new LineSegment(571539.1685,7015926.3927,571522.4107,7015930.0191));
polygonSegmentList.Add(new LineSegment(571522.4107,7015930.0191,571524.1421,7015941.2393));
polygonSegmentList.Add(new LineSegment(571524.1421,7015941.2393,571539.1685,7015941.582));
polygonSegmentList.Add(new LineSegment(571539.1685,7015941.582,571539.1685,7015945.6416));
polygonSegmentList.Add(new LineSegment(571539.1685,7015945.6416,571560.8646,7015942.2022));
polygonSegmentList.Add(new LineSegment(571560.8646,7015942.2022,571554.5927,7015904.3921));
polygonSegmentList.Add(new LineSegment(571554.5927,7015904.3921,571567.0612,7015908.2978));
polygonSegmentList.Add(new LineSegment(571567.0612,7015908.2978,571568.0242,7015907.1421));
polygonSegmentList.Add(new LineSegment(571568.0242,7015907.1421,571560.4466,7015900.4921));
polygonSegmentList.Add(new LineSegment(571560.4466,7015900.4921,571561.2404,7015896.259));
polygonSegmentList.Add(new LineSegment(571561.2404,7015896.259,571577.0933,7015896.259));
polygonSegmentList.Add(new LineSegment(571577.0933,7015896.259,571578.9674,7015894.0101));
polygonSegmentList.Add(new LineSegment(571578.9674,7015894.0101,571564.2792,7015888.2747));
polygonSegmentList.Add(new LineSegment(571564.2792,7015888.2747,571563.5545,7015873.0528));
polygonSegmentList.Add(new LineSegment(571563.5545,7015873.0528,571574.5472,7015873.5045));
polygonSegmentList.Add(new LineSegment(571574.5472,7015873.5045,571573.7534,7015854.7191));
polygonSegmentList.Add(new LineSegment(571573.7534,7015854.7191,571550.2056,7015853.9253));
polygonSegmentList.Add(new LineSegment(571550.2056,7015853.9253,571557.6253,7015846.5944));
polygonSegmentList.Add(new LineSegment(571557.6253,7015846.5944,571554.4348,7015834.4702));
polygonSegmentList.Add(new LineSegment(571554.4348,7015834.4702,571552.4354,7015825.4736));
polygonSegmentList.Add(new LineSegment(571552.4354,7015825.4736,571540.9927,7015827.059));
polygonSegmentList.Add(new LineSegment(571540.9927,7015827.059,571533.5882,7015833.8938));
polygonSegmentList.Add(new LineSegment(571533.5882,7015833.8938,571529.0315,7015843.577));
polygonSegmentList.Add(new LineSegment(571529.0315,7015843.577,571523.3354,7015845.8551));
polygonSegmentList.Add(new LineSegment(571523.3354,7015845.8551,571509.5472,7015846.6466));
polygonSegmentList.Add(new LineSegment(571509.5472,7015846.6466,571516.6826,7015892.8921));
polygonSegmentList.Add(new LineSegment(571516.6826,7015892.8921,571518.9382,7015907.5118));
polygonSegmentList.Add(new LineSegment(571518.9382,7015907.5118,571528.4449,7015904.4416));
polygonSegmentList.Add(new LineSegment(571528.4449,7015904.4416,571532.7326,7015904.4416));
polygonSegmentList.Add(new LineSegment(571532.7326,7015904.4416,571533.0657,7015909.2146));
polygonSegmentList.Add(new LineSegment(571533.0657,7015909.2146,571519.7112,7015912.5242));
polygonSegmentList.Add(new LineSegment(571519.7112,7015912.5242,571521.0792,7015921.3871));
polygonSegmentList.Add(new LineSegment(571521.0792,7015921.3871,571533.8691,7015920.7287));
polygonSegmentList.Add(new LineSegment(571533.8691,7015920.7287,571534.1331,7015924.5101));
polygonSegmentList.Add(new LineSegment(571534.1331,7015924.5101,571539.1685,7015924.7618));
polygonSegmentList.Add(new LineSegment(571539.1685, 7015924.7618, 571539.1685, 7015926.3927));
var polygonbuilder = new PolygonBuilder(new SpatialReference(3067));
polygonbuilder.AddPart(polygonSegmentList);
var polygon = polygonbuilder.ToGeometry();
try
{
var reshapeGeometry = GeometryEngine.Reshape(polygon, polyline);
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
}
}
... View more
02-25-2016
03:05 AM
|
0
|
2
|
2386
|
POST
|
I actually found the answer already. It was posted before here: Export WebMap PDF Legend Changing the default paper size for ArcGIS Server account fixed the legend. Just leaving this here if somebody has the same problem.
... View more
12-14-2015
12:23 AM
|
0
|
0
|
418
|
POST
|
Hi, I'm using Esri.ArcGISRuntime.Tasks.Print.PrintTask and ArcGIS Server ExportWebMap.GPServer to print maps from a MapView in my application. I'm using the default A4 Portrait template and the printing itself is working fine. The problem is that if I use PDF format, the legend icons do not look as they should look. I have attached both PDF and JPG print example results from the same MapView and the legend icons should always look as they are in the JPG version. Has anyone else encountered similar problem? Is there possibly something in the print template or in the Esri.ArcGISRuntime.Tasks.Printing.PrintParameters that I could modify to make the legend icons work in PDF too? Regards, Tuukka J
... View more
12-13-2015
11:48 PM
|
0
|
1
|
3346
|
POST
|
I still have problems with Print.Task and labels. I want to print a map where I show only features based on expression and I also need to show labels for these features. So far I'm able to limit features by setting a where clause on feature table of FeatureLayer and adding it to MapView to be printed or by adding the features I want to print to a graphic layer as graphics and adding it to the MapView. However, In these both cases the printed output does not contain feature labels. The labels are visible if I add the layer to MapView as ArcGISDynamicMapServiceLayer from the MapServer but in this case the layer definitions don't seem to affect feature visibility in the print result. Is there way to show the labels and hide features based on expression at the same time?
... View more
06-10-2015
05:42 AM
|
0
|
0
|
282
|
POST
|
Hi, I'm working on the reproducer app but I'm quite busy with other things at the moment so I will let you know when I'm able to finish it. I was mainly just interested in if somebody has experienced anything similar or if it was a known issue.
... View more
05-28-2015
02:36 AM
|
0
|
0
|
317
|
POST
|
Hello, I'm trying to sync data back to ArcGIS server from my offline geodatabase and in one table new features have their foreign keys set to null during the sync. I have an application where I have tables A, B, C, D and E. Tables D and E have geometries. There are globalid based relationships between A and B, B and C, C and D, D and E. When creating the replica, it uses layerqueries to take rows only to geodatabase table A. The user then creates rows for tables B, C, D and E in offline mode, so all features in these tables are new. When user has created all necessary data in offline, user tries to sync it back to the ArcGIS server. At this point, I can check the .geodatabase file and see that the data is fine and all relationships are working. However, when the data is synced back to the ArcGIS Server, for some reason, all the foreign keys in the table D are set to null. I tested this various times and noticed that this only happens when user adds data to table E as well. If the user does not add any rows to table E, the foreign keys are saved correctly in the sync process. In the attached screenshot, it is possible to see that the two rows are okay in the .geodatabase file but when synced and viewed from the online database, the foreign keys "MKIKUVIONTARKASTUS_GLOBALID" are set to null. All other data in synced tables is synced correctly. Is there any explanation that could possibly cause this? Has anyone else experienced similar problems? Regards, Tuukka Järvinen
... View more
05-20-2015
11:45 PM
|
0
|
3
|
3536
|
POST
|
After further testing I actually noticed that the request SR is not dependent on Map.SpatialReference but MapView.SpatialReference. The MapView gets SpatialReference from the first layer that gets added, right? For some reason, if I add FeatureLayer from ArcGIS server that has spatial reference WKID 3067 the MapView.SpatialReference is set to WKID 3067. But when I add ArcGISDynamicMapService layer with the same WKID 3067, the MapView.SpatialReference is set to WKID 102139. Both layers have their spatial references marked as "Spatial Reference: 102139 (3067)" on ArcGIS Server. What would be the best way to make sure that the MapView.SpatialReference is always 3067?
... View more
02-17-2015
02:23 AM
|
0
|
1
|
591
|
POST
|
I actually noticed that the API calls WMS with the following: http://geoserv.stat.fi:8080/geoserver/vaestoruutu/ows?SERVICE=WMS&SERVICE=WMS&REQUEST=GetMap&WIDTH=1185&HEIGHT=588&FORMAT=image%2Fpng&LAYERS=vaki2011_1km&STYLES=&BGCOLOR=0xFFFFFF&TRANSPARENT=TRUE&VERSION=1.3.0&CRS=EPSG:102139&BBOX=185176.859238558,6948504.12867242,773049.442264974,7240207.99265514 which returns this: "Error occurred decoding the espg code urn:x-ogc:def:crs:EPSG:102139 No code "EPSG:102139" from authority "European Petroleum Survey Group" found for object of type "IdentifiedObject"." If it would send the request with EPSG:3067 which is the spatial reference of my map, the request would work like this: http://geoserv.stat.fi:8080/geoserver/vaestoruutu/ows?SERVICE=WMS&SERVICE=WMS&REQUEST=GetMap&WIDTH=1185&HEIGHT=588&FORMAT=image%2Fpng&LAYERS=vaki2011_1km&STYLES=&BGCOLOR=0xFFFFFF&TRANSPARENT=TRUE&VERSION=1.3.0&CRS=EPSG:3067&BBOX=185176.859238558,6948504.12867242,773049.442264974,7240207.99265514 Is there any way to make it use correct SR in the request?
... View more
02-16-2015
03:22 AM
|
0
|
3
|
591
|
POST
|
The server returns correct image with SR 3067 if the bounding box is set correctly. http://geoserv.stat.fi:8080/geoserver/vaestoruutu/ows?SERVICE=WMS&REQUEST=GetMap&WIDTH=1921&HEIGHT=1018&FORMAT=image%2Fpng&LAYERS=vaki2011_1km&STYLES=&BGCOLOR=0xFFFFFF&TRANSPARENT=TRUE&VERSION=1.3.0&CRS=EPSG:3067&BBOX=46167.837979319,6629395.36843484,762231.492641991,7810900.49878568 I'm still wondering what causes it not to be drawn on the map after adding it as WmsLayer.
... View more
02-16-2015
12:24 AM
|
0
|
4
|
591
|
POST
|
Hi, I would like to show a layer from a WMS-service on my map but somehow it draws nothing. The WmsLayer.ServiceInfo is loaded correctly after initialization. I try to add it to my map with the following code where "vaki2011_1km" is the layer name from service ( http://geo.stat.fi/geoserver/vaestoruutu/wms?service=wms&%20version=1.3.0&request=GetCapabilities ). var wmslayer = new WmsLayer(new Uri("http://geo.stat.fi/geoserver/vaestoruutu/wms?"))
{
DisplayName = "Väestöruutuaineisto",
IsVisible = true,
};
wmslayer.Layers = new[] {"vaki2011_1km"};
wmslayer.ImageFormat = "image/png";
await wmslayer.InitializeAsync();
Map.Layers.Insert(0, wmslayer); My map spatial reference is EPSG:3067 and the WMS Service supports it. What can possibly go wrong here? I tried to publish a simple own WMS service on ArcGIS server and added it to my map same way and it worked fine.
... View more
02-13-2015
06:11 AM
|
0
|
6
|
4446
|
POST
|
Hi, Is there any way to get any visible labeling for a map printed with PrintTask?
... View more
02-11-2015
01:33 AM
|
0
|
1
|
282
|
POST
|
Thanks for the replies. I have access to feature data so I'm able to create a Runtime Geodatabase and after little bit of testing I think it can be used in this case. Is there any way to create these read-only Runtime Geodatabases programmatically?
... View more
12-04-2014
02:41 AM
|
0
|
2
|
401
|
POST
|
Hello, I would like to make an application to work offline. I have ArcGIS Server Services with sync capabilities and I'm able to create a replica for all the data that I need to edit offline and it's working great. I also have background map service that I can export tiles from and make a tile package for offline use. However, I'm wondering what is the best practice to get vector data from outside source to work offline. For example, I'm using property register data from a service that I'm not managing and not able to turn sync capability on. I don't need to be able to edit this data and in my understanding the sync is meant to be used only for data that needs to be edited. Should I use map packages in this case? From documentation I understood that I can create LocalMapService from map package in Runtime and add layers from it to my MapView, but can I perform Identify and Query task on these layers? Or is there some better way of doing this? Regards, Tuukka Järvinen
... View more
12-03-2014
01:34 AM
|
0
|
5
|
3061
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:24 AM
|