.NET

Reply
Active Contributor
jramos
Posts: 26
Registered: ‎01-16-2007
Message 1 of 2 (70 Views)

Events with C#

70 Views, 1 Replies
02-14-2007 02:53 AM
I'm developing an application for AutoCAD 2005 with C# (using COM). Most of the features I had to implement are done but now I can't figure out how to make events work (ObjectAdded and ObjectErased are never called). I searched the Help and it says that one must "Enable Document Level Events in Environments Other Than VBA" and they have an example on how to do it, but it's not in C# and I can't simply figure it out...

Can someone help? Thanks...
*Bobby C. Jones
Message 2 of 2 (70 Views)

Re: Events with C#

02-14-2007 06:17 AM in reply to: jramos
If you're an AUGI member you can download past AU handouts.

http://www.augi.com/education/auhandouts.asp

Get 'AutoCAD Automation with C#'. It's all about com interop with C# and
AutoCAD. The PDF has a section on hooking into events.
--
Bobby C. Jones
http://BobbyCJones.spaces.live.com

wrote in message news:5485955@discussion.autodesk.com...
I'm developing an application for AutoCAD 2005 with C# (using COM). Most of
the features I had to implement are done but now I can't figure out how to
make events work (ObjectAdded and ObjectErased are never called). I searched
the Help and it says that one must "Enable Document Level Events in
Environments Other Than VBA" and they have an example on how to do it, but
it's not in C# and I can't simply figure it out...

Can someone help? Thanks...
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.