vektorwerke-affe Posted September 7, 2022 Share Posted September 7, 2022 Is there a way to rename a class with multiple subclasses? For example I have just imported a civil engineer's CAD survey and it has hundreds of classes with subclasses, all using standard abbreviations. Unfortunately the file was a mess and most of the information will just be deleted. There are some classes I would like to keep and rename more legibly, but I'd rather not individually change the base class name ten times. In a related vein, some of the imported linework is at an accurate height, but a lot of it has seemingly random height values, like tree symbols, leader lines, and text notes sitting a quarter mile up above the topography. Is there a way to select all items on a class (other than just turning all other classes invisible, and selecting what's left). In Rhino if you do a Select All Objects On Layer (Rhino layer being comparable to VW class) command, it would warn you that some items of that description were not currently visible and prompt to turn on. That's the functionality I'm trying to recreate. Quote Link to comment
MarcelP102 Posted September 7, 2022 Share Posted September 7, 2022 For renaming check this script: I'm currently away from keyboard, but if I'm not mistaking this can also rename multiple classes at the same time. Quote Link to comment
michaelk Posted September 7, 2022 Share Posted September 7, 2022 I think Tools > Batch Rename will take care of the classes. The Select Similar Tool (in the Basic tool palette - looks like a magic wand) will do exactly that. Quote Link to comment
Jesse Cogswell Posted September 7, 2022 Share Posted September 7, 2022 (edited) @MarcelP102 is correct, this plug-in will work on any named object, including classes and layers. It makes renaming classes and removing parent classes really simple. To install, follow the instructions below: Download attached .vsm file Find your User Folder. The quick and dirty way to do this is to go to your Vectorworks Preferences, go to the User Folder tab, then click on Explore / Open in Finder. This will open your user folder in a separate window. In the explorer/finder window, find the Plug-ins folder and open it. Move the downloaded .vsm file into the Plug-ins folder. Restart Vectorworks. Now, you will want to add the menu command to your workspace. Go to Tools - Workspaces - Edit Current Workspace. Make sure that the Menus tab is selected. In the box on the left, expand the category JNC, you should see a command called Replace Name Text. In the box on the right, find a menu where you want to access the command (such as Tools). Drag and drop the command from the box on the left to the box on the right. Click OK. The tool allows you to have only look at selected objects (for renaming Viewports, for example), and the list browser is automatically sorted by object type. It looks at Plug-in Objects, Layers, Classes, anything with a name aside from Symbol Folders (there is a bug where changing the symbol folder name with a script doesn't properly update the Resource Manager, so the folder essentially disappears, so I removed that possibility). It will highlight whether the resulting change will cause a naming conflict with another resource as well. You can leave the Replace With text box empty if you want to remove text. Please let me know if you have any questions. I should also mention that this tool will work with any version of Vectorworks from 2019 to the current release (and presumably 2023, won't know until it releases). Replace Name Text.vsm Edited September 7, 2022 by Jesse Cogswell 3 Quote Link to comment
vektorwerke-affe Posted September 7, 2022 Author Share Posted September 7, 2022 batch rename! should have known. Thank you. Select Similar is not quite what I'm looking for because it requires that you are currently looking at an object in that class. A problem I'm having is that I'll have just one class set to visible in the class list, and every layer (there are only two right now) set to Show/Snap/Modify, nothing locked, and no layers have any classes invisible, and nothing is visible or selectable on the screen (with cmd+A, zoom to fit objects). So if there's anything on that class, it should be visible. I right click on the class and delete it, and it asks what to do with items on that class, so something's hiding from me. Basically what I need is to force visibility and selection on a class. Quote Link to comment
Jesse Cogswell Posted September 7, 2022 Share Posted September 7, 2022 I also have a tool that can be used to track down any objects using a selected class, such as objects embedded in symbols, groups, viewport annotations, etc. It can be found in this post: Quote Link to comment
P Retondo Posted September 8, 2022 Share Posted September 8, 2022 The best way to deal with AutoCAD engineering files with all those problematic conventions is to keep them in a separate file and reference into the file you are working with. Just leave all those 500 classes alone. To select objects globally in a certain class or classes, use "Custom Selection," which opens a dialog box allowing you to create a selection command for any number of parameters. To turn on visibility of all classes, go the navigation palette, classes, and Alt+click on the left hand column of any item to turn all visible. 1 Quote Link to comment
P Retondo Posted September 8, 2022 Share Posted September 8, 2022 Also, to remove subclasses, delete all the classes in question after creating a new class you would like to assign to those objects. 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.