Plugins can listen for events they get called notifications and you can register to a large number that illustrator provides.
However you might want to have a look at CS Extension Builder it comes with a plugin and matching actionscript library that we call HostAdapters that allows you to listen for those sorts of events using actionscript in Ai, ID and PS. This means that you do not have to write your own plugin to do so.
If you find this doesnt meet your needs and want to create your own plugin the way that the host adapters work is register for the notifactions required and then simply forward them to actionscript.
I hope that helps,
Thanks Robert, I recall looking at that CS Extension Builder once before… I will go look again but think you need to sign up to a developer program that costs (ouch)… I don't know actionscript is it a big learning curve and step up from extendscript?
Robert, I took a look over at the dev centre and in amongst the samples is an AI ID & PS events snippet… Actionscript I may be able to get my head around… plug-ins would probably be beyond me… thanks
Yes the jump from extendscript to actionscript is much smaller than to C++. If you have any questions about developing an extension there are two good forums:
http://forums.adobe.com/community/creativesuites/cs_sdk and http://forums.adobe.com/community/creativesuites/extensionbuilder which are good for asking for help on.
Bob thats where I was looking last night… Actionscript looks a possibility… Watched the intro stuff… Doesn't look too dissimilar to Extendscript… C++ is out going to be way out of my depth me thinks…
Edit: When I started to learn extendscript there were rumors it wasn't going to last. I almost went with actionscript is this going to be around long enough for me to learn and make use of?