IKeo Posted August 27, 2002 Share Posted August 27, 2002 I am trying to write PIO scripts which put everything that is created in the script onto a certain layer, and then revert back to the orginal layer. The "Layer" command just makes a new layer but doesn't create the objects following it on that layer. I thought that was what this command was for. Any suggestions would be greatly appreciated. Quote Link to comment
Guest Posted August 28, 2002 Share Posted August 28, 2002 That does not really fit in with the purpose of plug-in objects. Perhaps you would be better off developing a plug-in tool. Plug-in object scripts are just supposed to create the sub-objects that define the object. They are not supposed to create objects on other layers. Here is a little behind the scenes info: When an object is reset, VectorWorks will actually set the current layer to be the plug-in object node itself and then it calls the script. Now in the script, when objects are created they are automatically in the plug-in object's sublist. Quote Link to comment
IKeo Posted August 28, 2002 Author Share Posted August 28, 2002 Very interesting and informative! Here's my problem. I am building several drawing tools (labels, section markers and the like) which I want to have the behavior of PIOs (i.e. linear labels, rectangular detail markers). If I build them as tools, then they are just a group of objects or, at best, a symbol, which to my understanding then can't be edited like a PIO (i.e. editable text fields and such). Therefore it seems that I am searching for a way to get the layer information from inside the PIO, much like you can get the rotation info. Perhaps there is no way to do this, but it sure would be nice. Perhaps an addition in VW10 to the PIO "Object Properties" dialog, that asks for the "Default Layer" as well. Thanks again. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.