ExternalEvent raised during DocumentChanged from a Paste operation does not execute
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
In the sample code, ControlledApplication_DocumentChanged calls Raise() for each Id in GetAddedElementIds()
If you invoke the wall tool and click twice to create a straight wall, 1 element is added and Raise() is called once. When you end the Wall editor (hit ESC twice), the Raise code is executed. Everything is good.
If you copy/paste this wall (select it, CTRL-C, CTRL-V, click to place the new wall), then 4 elements are added and Raise() is called 4 times. Push ESC or Finish Paste to complete the Paste command. The Raise code is only executed one time. What happened to the other 3 calls to Raise()?
I have try/catch blocks around all the relevant code and there are no exceptions. The Raise code is only showing a Task Dialog (for debugging purposes).
Relevant code is in https://bitbucket.org/BoostYourBIM/boostyourbimterrifictools/src/master/BoostYourBIMTerrificTools/Ri... lines 130-151