and have tried to bring those scripts into revit with dynamo player, in an attempt to make a workflow for cleaning up drafted lines in a model, so that they meet company standards. we always get a handful of unique linestyles cropping up - that look nothing like the existing standard linestyles. prior to making a new linestyle to accomodate the deviation, i want to be able to see how the line is being used - and if it is necessary, or if it is simply a result of someone importing a view from another file.
short of selecting all lines of all types in the entire project, and then filtering it down to the linestyle i want… It would be nice to be able to select just those line i want to inspect (Get item id → Select by ID → Show in model)
Any help you all can offer would be greatly appreciated.
But then i save the script, and load it into dynamo player, and it makes no selection when i run it. i have tried re-entering the string contents with various line style names, and they all work inside of dynamo, but not within the player.
Okay - that definitely made forward progress. Thank you. However, it still does not actually seem to be SELECTING the lines… its just adding them to a list. Is there a way to get the lines to be actually selected so that Revit recognizes that they currently selected?
YES!!! Thank you. Wow I have so much to learn… I had just found an Iron Python script for selecting items in Revit, and it wasn’t working… I guess that was because i hadn’t flattened the list…
So even though the results of the queries had all been single lists (0 List), it still needed to be flattened? Can you help me understand this any better, by any chance.
There are many ways to handle singleton, list of elements or list of lists in python.
In this particular case, the python script doesn’t iterate the list of list.
But if you start a new topic, you will have help to change the python script.
This subject can be interesting for people who want to improve their python skills.