POST
|
Hi, I used EditGeometry for resizing and moving objects (rectangle, for example). And it works fine except for this scenario: 1. Draw something 2. Click on drawing 3. Now select one of anchor points for resizing 4. Move mouse cursor away from the map 5. Observe as soon as you get out map area object is no longer resizing I noticed that when I'm drawing an object, I don't have this problem, only while editing with EditGeometry. Can this be fixed and how? Thank you, Ana Hi Ana, The behavior you are seeing is as designed. Only those shapes can be drawn outside map area which have mouse gestures of click and drag, i.e. Triangle, Rectangle, circle, ellipse, arrow, line. Shape like Polyline, Polygon or even point cannot be drawn outside map area. Interactive editing of any shape cannot be done outside of map-area. Thanks, Preeti
... View more
06-28-2013
02:10 PM
|
0
|
0
|
267
|
POST
|
Hi, These operations are available Out-of-the box. you don't need reference to any toolkit to be able to Pan, Zoom-in or Zoom-out. Thanks, Preeti
... View more
06-28-2013
01:34 PM
|
0
|
0
|
599
|
POST
|
Hi, This looks like a bug. I assume it got introduced as part of another improvement we did to enable saving edits for a polygon while it's vertices are being edited . We will try to fix this in future release. Thanks, Preeti
... View more
06-28-2013
11:11 AM
|
0
|
0
|
197
|
POST
|
Hi, This looks like a bug. I assume it got introduced as part of another improvement we did to enable saving edits for a polygon while it's vertices are being edited . We will try to fix this in future release. Thanks, Preeti
... View more
06-28-2013
10:14 AM
|
0
|
0
|
623
|
POST
|
Actually the problem is that you are trying to add a graphic with envelope as geometry when layer expects geometry of type polygon. In your sample code if you change the code as follows, the graphic will be saved correctly. ESRI.ArcGIS.Client.Geometry.Polygon poly = new ESRI.ArcGIS.Client.Geometry.Polygon();
ESRI.ArcGIS.Client.Geometry.PointCollection pts = new ESRI.ArcGIS.Client.Geometry.PointCollection();
Graphic gra = new Graphic();
//gra.Geometry = new Envelope(LL, UR);
pts.Add(LL);
pts.Add(new MapPoint(UR.X, LL.Y));
pts.Add(UR);
pts.Add(new MapPoint(LL.X, UR.Y));
poly.SpatialReference = MyMap.SpatialReference;
poly.Rings.Add(pts);
gra.Geometry = poly;
gra.Symbol = featureLayer.Renderer.GetSymbol(gra);
featureLayer.Graphics.Add(gra);
... View more
05-13-2013
01:27 PM
|
0
|
0
|
324
|
POST
|
Let me explain again.I believe there is some confusion here. You may be wondering why Toad or SQL client can return 3500( just an example) records and the same query is returning only 500 when executed from the API. It is because the map service you are querying is set to return maximum of 500 features. Again this is a value that can be changed. You may ask the publisher of the service to change this value to a higher number but please keep in mind the performance Here are couple examples: 1. Here is the URL from a 10.1 service http://serverapps101.esri.com/arcgis/rest/services/USA_Diversity/MapServer/3. Go to this URL and see MaxRecountCount property for this service is 1000. This means if the query returns are more than 1000 records using DB client records than irrespective of how many records are returned from the database ArcGIS Server service will return only 1000 ( using Rest endpoint or by using Any API querytask). Please note, this number is set while publishing a service and may be changed. At 10.1 this maxrecordcount property is exposed via Rest, so if you are using pre 10.1 server you may have to check this value using ArcGIS Server Manager or ArcCatalog. Bottomline, its not the database, its not the API but actually it is a value set on the ArcGIS Server service which causes querytask to return 500/1000 or whatever number set on the service. I am also attching two screenshots with two different values on two different services on the same server. I hope this makes it clear. Please let me know if you have any questions.
... View more
08-03-2012
01:55 PM
|
0
|
0
|
1163
|
POST
|
The workflow in your sample seems bit off.. In your case you will have to eliminate EditorWidget from the equation and craft your own editing toolbar using Editor. For help on this refer to sample link below: http://resources.arcgis.com/en/help/silverlight-api/samples/start.htm#EditToolsExplicitSave You may also use TemplatePicker for ease of adding features. I have done a small sample just to give you an idea on how you can achieve this. Please note code attached is for demonstration purpose only. To use sample add a polygon using Templatepicker, when add is completed, you may click on another feature which will select them. That happens because when Add is complete I execute Select action. For editor you don't have to set layerids or Map everytime to wish to start a new action. This should be done once. If no layerIds are specified Editor works on all editable layers in the map. To limit editor to work on specific layers layerids must be specified. I hope this helps. Please let me know if you have any questions. --Preeti
... View more
08-03-2012
01:19 PM
|
0
|
0
|
455
|
POST
|
You could use a non-secured service for editor tracking. As Dan mentioned there will be no user name for creator/editor fields. CreatedOn and EditedOn edit tracking fields will get value anytime a new feature is created or edited. And yes if you want to have user's email then you should have a field in you database that can be used for accepting email. Lets say you have an email-id of the logged in user then you before saving the edits you can simply add to the attribute in the code behind.
... View more
08-02-2012
09:14 AM
|
0
|
0
|
376
|
POST
|
private void locateFeature(Selection sel)
{
string serviceURL;
if (GravityMain.Target == PipeQueryBuilder.AddIns.MyDatabaseService.Table.SSGRAVITYMAIN_MV)
serviceURL = "http://whatever/";
else if (GravityMain.Target == PipeQueryBuilder.AddIns.MyDatabaseService.Table.SSPRESSURIZEDMAIN_MV)
serviceURL = "http://whatever/";
else if (GravityMain.Target == PipeQueryBuilder.AddIns.MyDatabaseService.Table.SWGRAVITYMAIN_MV)
serviceURL = "http://whatever/";
else
serviceURL = "http://whatever/";
// Query task initialization.
QueryTask queryTask = new QueryTask(serviceURL);
queryTask.ExecuteCompleted += QueryTask_ExecuteCompleted;
queryTask.Failed += QueryTask_Failed;
// Query task parameters. Return geometry,
Query query = new Query();
query.ReturnGeometry = true;
query.OutFields.Add("*");
query.Where = constructWHERECLAUSE(sel);
queryTask.ExecuteAsync(query);
}
public string constructWHERECLAUSE(Selection sel)
{
string whereclause = string.Empty;
whereclause += "PIPEMATERIAL = " + "'" + sel.PipeMaterial + "'" + " AND WIDTH IN (" + GravityMain.conCatSizes(sel) + ")";
whereclause += " and status = 1 ";
if (sel.Owner != 0)
whereclause += " and ptable.ownership = " + "'" + sel.Owner + "'";
if (sel.SubType != 0)
whereclause += " and subtype = " + "'" + sel.SubType + "'";
if (sel.Rehab != "ALL")
whereclause += " and rehabtype = " + "'" + sel.Rehab + "'";
if (sel.SanitaryOption != SanitaryOptions.NOT_SANITARY)
if (sel.SanitaryOption == SanitaryOptions.COMBINED)
whereclause += " and ((SUBSTR(FACILITYID, 19, 1) = 'C') or (SUBSTR(FACILITYID, 21, 1) = 'C'))";
else if (sel.SanitaryOption == SanitaryOptions.SANITARY)
whereclause += " and ((SUBSTR(FACILITYID, 19, 1) = 'S') or (SUBSTR(FACILITYID, 21, 1) = 'S'))";
return whereclause;
}
Can I use QueryTask Where clause like in the code above? The above code works but it appears that it does not return all the features on the map that meets the SQL criteria. My only reasonable suspicion is that the QueryTask where clause gets confused when it sees the SUBSTR( ). I am not sure because the code runs fine with no exceptions or compile error. The only thing is that it does not return all the features that meets the SQL criteria and other times it does return all the features that matches the SQL criteria. Does anyone have any suggestion that might be helpful. I need help with this. Thanks in Advance. It may be related to maximum records returned by the server. For e.g if max # of features returned is set 1000 for the service and query leads to more than 1000 features then only 1000 will be drawn/rendered. An easy way to test would be to use the SQL where clause using service rest end point and see how many records you get.
... View more
08-02-2012
09:05 AM
|
0
|
0
|
1163
|
POST
|
If I understood it right, you are trying to initiate another edition action when condition in EditorWidget_EditCompleted is true. If that's correct then changing the editor action is not exposed via EditorWidget. You need more granular control on edit actions and hence should use Editor which is more granular. Something like this... Also see sample in link below on how to set up Editor http://resources.arcgis.com/en/help/silverlight-api/samples/start.htm#EditToolsExplicitSave void editor_EditCompleted(object sender,Editor.EditEventArgs e) { FeatureLayer horizontalWellCap = TabletMap.Layers["1"] as FeatureLayer; FeatureLayer horizontalwellLateral = TabletMap.Layers["2"] as FeatureLayer; if (e.Action == Editor.EditAction.Add) { foreach (Editor.Change change in e.Edits) { if (change.Layer != null && change.Layer == horizontalWellCap && change.Graphic != null) { if (editor.Select.CanExecute("new")) editor.Select.Execute("new"); } } } } Hope this helps..
... View more
08-01-2012
05:04 PM
|
0
|
0
|
455
|
POST
|
Hi all Anyone copy/pasted a polygon from one layer to another using Silverlight thanks This can be done using silverlight too. However you cannot directly add a graphic from one layer to another. You would need to clone the geometry and copy over attributes from LayerAGraphic to LayerBGraphic. Grpahic LayerBGraphic; = new Graphic(); LayerBGraphic.Geometry=ESRI.ArcGIS.Client.Geometry.Geometry.Clone(layerAGraphic.Geometry); foreach (var attrib in layerAGraphic.Attributes) { LayerBGraphic.Attributes[attrib.Key] = attrib.Value; }
... View more
07-30-2012
10:53 AM
|
0
|
0
|
173
|
POST
|
Add "using System.Linq;" to list of namespaces in the codebehind.
... View more
07-30-2012
10:32 AM
|
0
|
0
|
586
|
POST
|
Hi, Can you please elaborate on "when I go to print, it only shows up in black and white". Does the entire map shows black/white , including the basemap? or only Graphics are printed in black and white.Can you provide your XAML? Side note, The export web map task cannot print not any custom symbols. If there are any custom symbols for e.g. symbols using storyboards/gradients etc are downgraded to black point circle/line/polygon based on geometry type. --Preeti
... View more
07-27-2012
01:44 PM
|
0
|
0
|
595
|
POST
|
Hi , I don't see any techinical issue in what you are doing. I tried both of your usecases on http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/HomelandSecurity/operations/FeatureServer/2 and didn't run into any issue. Both cases were successful. For updating I did (MyMap.Layers[1] as FeatureLayer).SelectedGraphics.ToList()[0].Geometry = null; And for adding a new feature, private void Button_Click(object sender, RoutedEventArgs e) { Graphic g = new Graphic(); g.Attributes["collection_time"] = DateTime.Now; g.Attributes["description"] = "Empty Shape"; (MyMap.Layers[1] as FeatureLayer).Graphics.Add(g); } Try a simple usecase using service above and let us know if you find any problem.
... View more
07-26-2012
09:25 AM
|
0
|
0
|
673
|
POST
|
Magnifier actually makes the request to the map service or featurelayer service and gets the features. If the same service is added on the map and has some selections or custom symbology, magnifier cannot display it because it is not requesting image off a map. It will display the layer with default renderer/symbol or whatever comesback as part of layer info. Botton line is , I think it is not possible.
... View more
07-13-2012
03:22 PM
|
0
|
0
|
236
|
Title | Kudos | Posted |
---|---|---|
1 | a week ago | |
1 | 2 weeks ago | |
2 | a month ago | |
1 | 07-08-2024 07:33 PM | |
2 | 06-19-2024 02:12 PM |
Online Status |
Offline
|
Date Last Visited |
a week ago
|