thebud333

Combine Smooth and Generalize and enter default offsets

Discussion created by thebud333 on Aug 4, 2010
We digitize 1000s of polygons for geological mapping.  We have a process of using the smooth and generalize tools from the Advanced Editing toolbar to improve the appearance (just using smooth seems to cause crashing issues in 9..2).  I have code that has the 2 commands combined, so you only have to click one button - code below.  But the slow part is having to enter the offsets each time.  Does anyone have any ideas of how to write a script that when a polygon is selected in ArcMap the 2 tools run and automatically apply 2 default offsets?  If you need any more information please get in touch.



Public Sub CreateBar()
   '
   ' Get the commandbars collection
   '
   Dim pCmdBars As ICommandBars
   Set pCmdBars = ThisDocument.CommandBars
  
  Dim pUID As New UID
 
  pUID.Value = "{6185F30D-1B9A-470D-A52F-E37482D677FB}"
  Dim pCmdItem As ICommandItem
  Set pCmdItem = pCmdBars.Find(pUID)
  pCmdItem.Execute
 
  pUID.Value = "{E820DFD0-02F4-4FF2-B8A3-4BDCD0D2BD64}"
  Set pCmdItem = pCmdBars.Find(pUID)
  pCmdItem.Execute
 
End Sub

Outcomes