I'm afraid it's not nearly as simple as Joe seems to think. There's no functional equivalent to VBA's 'ThisDrawing' in .NET.
In VBA, 'ThisDrawing' is a reference to the active document, and its events.
When you handle an event of 'ThisDrawing' in VBA, the event fires for every document, not only the one you manually reference via MdiActiveDocument. In .NET, if you add a handler to an event of Document object returned by MdiActiveDocument, the event fires only for that document, it does not fire fir every document.
In VB.NET, you have to handle the events of the DocumentCollection class (e.g., DocumentAdded and DocumentToBeDestroyed), and in the handlers of those events, you must add/remove Document event handlers for each document.
I'm afraid that's not a trival task especially for an entry level programmer, however.
--
http://www.caddzone.com
AcadXTabs: MDI Document Tabs for AutoCAD 2009
Supporting AutoCAD 2000 through 2009
http://www.acadxtabs.com
Introducing AcadXTabs 2010:
http://www.caddzone.com/acadxtabs/AcadXTabs2010.htm
wrote in message news:5997576@discussion.autodesk.com...
Hey guys, I and trying this same thing and I am getting no where? Can you help me out?
Thanks
Big R