Sam Jones Posted March 28, 2021 Share Posted March 28, 2021 I'm pretty sure this can't be done, but I need to ask. After building a resource list I want to import only the symbols that are connected to a specified record. Is there a way to do this filter? Or, do I have to import each symbol in the list check for the record and delete symbols that do not have the record. If I do have to do that, how do I delete a symbol definition from a document, DelObject(HandleToSymDefinition)? Quote Link to comment
Julian Carr Posted March 28, 2021 Share Posted March 28, 2021 Not sure if it can work for you Sam, but I have two methods for doing this. The first is using symbols folders, so only the source symbols within a particular folder will get make it into the list. The second is using a prefix or suffix within the symbol name in conjunction with GetActualNameFromResourceList(). I don't think you can get a handle to symbols in a list though, which is obviously a requirement for checking for an attached record. Quote Link to comment
Vectorworks, Inc Employee klinzey Posted March 29, 2021 Vectorworks, Inc Employee Share Posted March 29, 2021 The symbols must be in the active document in order for VS to get any info about them other than than the name, so you will have to import them into the document in order to get any record information form the symbol. You should also look at using BeginContext() and EndContext() rather than just deleting the objects, it works better with the undo system and project sharing. 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.