We have dockable window with textbox and a button. The button run click event but need this button as a tool to capture polygon then update the attribute value in the polygon featureclass field.
No one here
As per another forum discussion created a class 'Draw Tool : ESRI.ArcGIS.Desktop.AddIns.Tool' added 'Draw Tool' in 'Config.esriaddinx' under commands
<Button id="DataCapture_DrawTool" class="DrawTool"...>
Then get the IDs.DrawTool button click event code: SnippetUIDClass uid = new UIDClass(); uid.Value = ThisAddIn.IDs.DrawTool; ICommandItem commandItem = ArcMap.Application.Document.CommandBars.Find(uid, false, false); ArcMap.Application.CurrentTool = commandItem;
At last line it thrown an error.
Error description: An unhandled exception of type 'System.ArgumentException' occurred in DataCapture.dllAdditional information: Value does not fall within the expected range
Appreciate your help in advance.
Angemeldete Mitglieder können Beiträge verfassen, Updates folgen und mehr. Neu hier? Registriere ein kostenloses Konto.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.