POST
|
I am developing a tool that uses a EditorExtension to save edits on the IEditor object in ArcMap 10.5. The save is triggered in an event handler for a custom event from another class. After some validation to ensure that the save can proceed, this code is used for saving the edits: if (this.Editor.HasEdits())
{
ArcMap.Editor.StopEditing(true);
ArcMap.Editor.StartEditing(workspace);
} The problem is that when a point feature has been created and the code is run, ArcMap throws a Access Violation exception (according to the Windows Event Viewer and the Minidump that is generated) and quits. This behavior does not occur when creating other types of features (polylines and polygons, for example), nor does it happen when modifying or deleting already existing features. If I use IWorkspaceEdit to save the edits, the problem doesn't occur. Normally, I would just go with that approach, but this is a tool for ArcMap, and I need to sync with the Editor environment there, as well as its events to modify my UI based on the edit state. I've tested with both versioned SDE data and feature classes stored in a file geodatabase, and the behavior is identical in both formats. I've been chasing this one for a few days and can't figure out the problem. If someone has any insight on what could be occurring here, I sure would appreciate it. We are running 10.5, so I realize that this may have already been fixed in newer versions of Arc. If so, that would be useful information to have as well.
... View more
06-15-2022
08:41 PM
|
0
|
0
|
367
|
POST
|
Hi Kirk and John-- Thanks for the replies. I was afraid that it was something internal that hasn't been publicly exposed by Esri. I'll work around it. I'll also see about posting an idea, as John suggested. -Matt
... View more
02-09-2021
08:07 AM
|
0
|
0
|
2043
|
POST
|
Hi Narelle-- Are you perhaps not wanting / expecting to see the green/red sketch vertices and the dotted sketch line that overlays your line? That is indeed what I was trying to do, if it's possible? Thank you, Matt
... View more
02-05-2021
01:39 PM
|
0
|
3
|
2089
|
POST
|
Hello, I am using version 2.6 of the ArcGIS Pro SDK to develop a custom MapTool for a line feature, and I seem to be having trouble setting a symbol for the feedback. Here is some relevant code: In the constructor, I have these parameters set: IsSketchTool = true;
SketchType = SketchGeometryType.Line;
SketchOutputMode = SketchOutputMode.Map;
UseSnapping = true;
IsWYSIWYG = true;
SketchMode = SketchMode.Line; In the OnToolActivateAsync method of my class I then set the symbol (after defining it) by calling: SketchSymbol = _lineSymbolReference; _lineSymbolReference is defined as: CIMSymbolReference _lineSymbolReference = await QueuedTask.Run(() => {
CIMColor lineColor = CIMColor.CreateRGBColor(237, 28, 36);
CIMLineSymbol lineSymbol = SymbolFactory.Instance.ConstructLineSymbol(lineColor, 1.5, SimpleLineStyle.Solid);
return lineSymbol.MakeSymbolReference();
}); When testing the tool in Pro, and drawing a sketch, the symbol always remains as the default symbol (the black dotted line, with the vertex symbols visible), though the symbol appears correctly after the sketch is finished. Is there a way to have the symbol be used when drawing the sketch? Thank you in advance for any help you might be able to provide!
... View more
02-05-2021
09:37 AM
|
1
|
7
|
2130
|
POST
|
Hi Uma-- I appreciate it. I'll take a look at those and see if they could work for us. Thanks, Matt
... View more
04-08-2020
11:56 AM
|
0
|
0
|
1065
|
POST
|
When loading a project in ArcGIS Pro, a busy indicator is placed over the map view to show that Pro is working on loading layers. In version 2.5, it looks something like this: I am trying to show it (or something similar) as my addin loads WMTS layers pulled from a web service. Is there a way to access or show this busy indicator via code? Thank you, Matt
... View more
04-08-2020
07:26 AM
|
0
|
2
|
1098
|
POST
|
Hello- In an application that I am developing using VB.Net with ArcObjects 9.3, I am trying to display the "Select By Location" dialog box in my code. I know that I can call it directly using the UID through the ICommandItem interface, but I also need access to the parameters set by the dialog box (something that I don't think is possible with the UID method) . Is there a way to do this somehow that I'm missing, similar to the way that you can call the "Select By Attribute" dialog box using the IQueryAttributes interface? Thanks, Matt
... View more
10-02-2014
03:08 PM
|
0
|
0
|
2401
|
Title | Kudos | Posted |
---|---|---|
1 | 02-05-2021 09:37 AM |
Online Status |
Offline
|
Date Last Visited |
06-15-2022
11:27 PM
|