Change Name parameter of Subcategories

Hi All,

I’m trying to change the name of the subcategories. A solution which consists of removing and creating new sub-categories with a different name that is not suitable for me.

Thank you in advance.

SubCategories.dyn (15.7 KB)

I tried to solve this problem differently. But in this case I meet a new problem.
This is the object that I want to change


And this - it’s a second way.

SubCategories_2.dyn (4.5 KB)

@DENIS.REMESNIK, I’m not sure if its possible to change the name of linestyles, but API in Revit 2017 allows you to create the new ones. See this post by @Jeremy_Tammik: http://thebuildingcoder.typepad.com/blog/2016/10/how-to-create-a-new-line-style.html

Thanks for your answer, this solution doesn’t work in my case, as I wrote above.
Can be it means that possible but there is another way?

I’m not aware of another way. Why isn’t this work around suitable in your case?

I have a ready project and family in this project consists of this type of my line. If I delete this line - line in my family will be remove.

You need to reassign the subcategory prior to deletion. Order should be:

  1. create new subcategories
  2. get all elements on the old subcategories and send their element IDs to an excel or text file
  3. assign new subcategories based on a dictionary setup
  4. delete old subcategories (which no longer contain any content).
  5. in a new dynamo graph read the list of element IDs from the external file and try to select them in the model. If they exist than you’re all set. If not undo, edit the script as required and try again.

ohh… Thank you for cool idea! I try it a few day later and let you know about my result!

Good luck and be sure to share the graph when you get it working. :slight_smile:

I have a great news! I a few changed this algorithm and realize - it’s worked! I sharing this node some times later in this topic!
P.S. Jacob you are best, one more thanks!

It’s prove for my words above:

1 Like

Thanks to everyone for the advice especially Jakob.
This is solution for problem above:
Change_GraphicsStyle_V1.0.dyn (19.5 KB)

1 Like

@DENIS.REMESNIK …Can You please share the file…Thank You