Identifying unused components

I’m always uncomfortable purging unused components without knowing exactly what is being flushed. My fear is that I may have accidentally deleted something from my model, or I may simply change my mind and want it back and won’t remember where I got it or how I may have modified it. Recently, I started using a special tag “Unused saved components”. This not only prevents them being purged, but it also keeps them exactly as I used them in their intended placement. This also allows me to easily go through these tagged components and purge manually if desired. However, since my model predates this tagging method, I may have components I want to keep that were never tagged. I’m way overdue for some housecleaning, so my questions are:

  1. Is my tagging system silly? Am I missing a more logical method of managing unused components I want to keep handy? After all, I’m the kind of guy who is nervous about emptying my computer’s trash and have all my emails back to 2009!
  2. Is there anyway to identify or highlight unused components in the browser before purging?
  3. Is it possible to select unused components and save them to a file before purging?
  4. Is there a way to get larger component thumbnails (I’m getting old and I’m working on a laptop).

Thanks in advance!

Add them to a collection for old stuff

But how do I select unused components to add them to a collection?

If you have two component windows open, one for “In Model” and One for “the unused components”.
The in model window shows all components in the model and you can drag them from the in model window to the window you set to hold the unused components. you can then open this collection in the future to insert them into the model if you need them later.
So you would do this before deleting them.
This method is courtesy of Dave.

You can see the dual component windows above.

OK, I like that idea, but I still don’t understand how to create a component window that only has unused components. It seems like you’re suggesting an organization method that presumes I’ve already identified and selected the unused components. That’s the key part I’m not getting.

You can also set all Tags to ‘unvisible’ but the current of course, which is ‘untagged’
Select the components and change the Tag in the entity panel.
Proceed till nothing is left.
Categorizing stuff in an ‘unused’ collection is against my logic, for it is immediately being used for that.

It would be nice to have some way’s to search the ‘in Model’ collection, a filter at the top like in the outliner could manage that perfectly.

“It would be nice to have some way’s to search the ‘in Model’ collection, a filter at the top like in the outliner could manage that perfectly.”

This is another point that has frustrated me. I’m sure I’m missing some functions and tricks, but why can’t I search my components by name? Why only the 3D warehouse? Add to that that the thumbs are so small, I sometimes have to drag a component into my model just to see what it is. That seems crazy!

I appreciate the organizational suggestions, but I still don’t know how to find and select unused components. The only command I’ve found is purge. But I just want to identify them, not necessarily purge them. Perhaps I was confusing in my original post where I said I have many unused components tagged as such. Those are easy to find and organize using some of the methods you described. But I have many more unused components that I can’t easily find other than click on every component in the browser looking for ones where “select instances” is greyed out. There’s got to be an easier way.

1 Like

Not natively in SketchUp. Save the collection to a folder ‘unpurged model x’ (check the litlle blue detail icon)
Purge the file, then save to a folder ‘purged model x’

1 Like

Anytime I create a component I might reuse, I immediately save it by dragging it into a local collection as @Zarloff described. Then it doesn’t matter if I purge it from the current file since it is still available to me. It takes a little discipline but it’s not a huge task if I keep up on it. Same thing works for my custom materials.I also sort the components into collections based on logical categories so they aren’t difficult to find later.

1 Like

I haven’t been using the save collections feature and can see the value of doing this. Can anyone point me to a tutorial or guide on this? I figured it out basically, but it’s not as intuitive as expected and I had to track down where it was saving the files.

Unfortunately, no one has suggested a way to identify and select unused components–which seems odd. I also work in audio and video editing where you have bins of files within a session, and there are commands for exactly that–“select unused files”. Once selected, you can delete, move, export, flag, etc.

It shouldn’t be odd that no one has suggested a way because there currently isn’t a way. Might be possible to write a script that could give you a list of the unused components although I’ve never seen such a plugin. Yours is the first request I’ve seen for such a thing in nearly 18 years of using SketchUp and hanging around the various SketchUp forums.

If you’re going to save all your In Model components into a single collection, set the Components panel to In Model. Open the Details menu to the right of the drop list/search line. Choose Save as local collection. Give the collection a name.

As I wrote, I prefer to sort my components into appropriate categories (and I rarely want to save all of the in model components into one collection) so I have folders created in my master Components local collection, I open the secondary pane and drag the thumbnails from In Model to the desired collection.

Thanks DaveR, this helps. I guess if no one has asked for this in 18 years I’ll quit asking. I came to Sketchup a few years ago from a background in audio and video engineering. I also have experience in mechanical engineering and construction. So while I’m new to Sketchup and 3D drawing, I’m not new to computer-based platforms that create stuff. I subscribe to these forums and have read many times as the generous contributors here have helped others better understand what Sketchup is and isn’t, and best practices for successful model building like the correct use of tagging (previously layers). 90% of the program I’ve come to appreciate for what it is, but sometimes it inexplicably breaks with logical conventions widely used in other programs for no apparent reason. For example, you can’t delete a component in the browser when it is selected. You have to make sure it is deselected and context click on it (without selecting it) to get the delete command. Now things like that don’t make sense regardless of what program you’re in. I would argue the same for not allowing you to identify your unused components in the browser. And I simply can’t understand why there isn’t more adjustability in the thumbnail size, or a context click to enlarge it. There’s basically just small and smaller. Every other program I work in offers much more flexibility in sizing icons, tools, and other parts of the UI. Maybe they’ll never change this stuff and most people won’t care. But I bet I’ve heard tech support people ask me “why do you want to do that? No one else has asked for that” a hundred times over the last 30 years, only to have the feature show up in a future release citing popular demand. In the meantime, I’ll adjust my methods and keep my head down.

1 Like

One last question on the component browser: I have found that when I am trying to find where a component is located in a model by using the context menu item “select instances” in the browser, it is greyed out and not findable if the component happens to be nested in a group. If you open the group, the browser will then allow you to select the instance, but if it’s closed, it’s invisible to the select instances command. Oddly, it will find the components if they are nested in another component, but not a group. Is there a logical reason for this?

Part of the SketchUp philosophy is that when you need extended functionality, you install an extension. While being part of it’s success, the counter thing is that It seems that ‘nothing ever happens to the core’

At the time, SketchUp’s UI was it’s time ahead.
But it is 2020, and some things could use an overhaul.
Like search filters in material or component panels.

Flextools has a nice component finder (free of the Flextools set)

1 Like

I just create a TEMP layer [tag] and place things I might need later there, turn it off until needed, delete when project finished

It is very simple to write a Ruby that will identify unused components - essentially a one-liner. If a pretty output is wanted that would be 95% of the work. On my phone now or I’d show a snippet

The Window menu>Model Info>Statistics dialog gives you a simple list of components that are inserted in your model when you select “Only components” from the top popup menu. Components not listed will be purged if you purge the model. When you select a component in the model, the Entity Info window will give you the number of similar components in your model. It might be a good FR to have this information shown in the Details or List view of the In Model components tray.

I’m not sure that’s a good reason to quit asking about it. I certainly didn’t mean to imply that.

1 Like

I have also encountered this problem and think I understand what result you want.

First of all, if you know that some components will need to be deleted from the project file but need to be kept in reserve, preserving not only their structure and appearance, but also their location, then start with the right work organization from the very beginning of the project, not when it is finished.

The method I use successfully in such cases is as follows:

First create an empty skp backup file, which is named after the existing project file by appending “unused” or similar code name. Keep both files open when working on a project!

Instead of deleting a component from the project file, Cut it (Ctrl+X) and Paste in Place (my hotkey Ctrl+Alt+V) into the created backup file. After work save both files, of course. In this case, you don’t have to worry about losing any components you need in the future, and you can any time safely Purge Unused components from the project file, as well as purge unused materials and tags.

Exactly the same method (Cut + Paste in Place) returns any of the components saved in the backup file to the project file, at the exact place from which it was taken. But before that, I definitely recommend using the SketchUp native Model Info/Statistics/Purge Unused command or some analog, extension command to avoid creating duplicate components or materials with #1, #2, etc. at the end.

Try it and tell us if it solved your problem!

1 Like

Yep, that’s basically one of my organizational methods. But still having trouble with the component browser.