Updating Object Style line weights

Starting up a new thread since didn’t get feedback after a day of posting on a previous thread.

Link to other thread:
LINK

It appears that the script I put together works because there are not errors or nulls, but nothing seemed to change in my object styles. So I’m looking for some help on what part I’m missing.

Thanks

The reason that nobody answered might be that everybody focusses on Filters.
not sure

I was working on the assumption that when I replied on a thread that whomever was in the thread gets dinged, they then go look to see the new reply and respond if they wanted to.

Are you referring to the tags associated with each thread when you mention filters?

Filters in Revit off coarse, sorry

I’m not following how Revit filters relates to a script that changes a bunch of object styles line weights at one time

Well, Filters are like Object Styles square, in power, to change Line Weights with an override, since overrides can be set to finer grain, whatever Object Style is saying. So if there are Filters at work, you can change Object Styles, but they may be overridden, so you don’t see a change.

Edit the last custom node, and bring the guts of the dyf into the dyn via copy-paste. Wire things in to see what errors are popping up. Careful with inputs expecting lists/single items. Working on a subcategory element instead of a list thereof might help to start.

1 Like

Hi,

The custom node is working fine so it is probably a matter of list level or lacing.
Did you try with the longest lacing ?

1 Like

I tried to capture a few things in this screenshot.

  1. I tried changing it to longest lacing and I received ‘nulls’

  2. I opened the custom node and tried to look at the Python code and nothing appears.

  3. I tried running it with the nodes pasted into the overall environment and didn’t get any errors and it didn’t work.

Based on that it worked for you when you provided a number, is there is issue with how the list is input into the custom node?

There is an error in the screenshot because that was me trying to a few other things after pasting in the custom node and then reattaching the nodes back to the custom node.

Hi,

Can you share a sample project with only the relevant informations (casework category) and your Dynamo graph ?
You can share it by private message if necessary.

1 Like

It won’t let me upload or send a Revit Template File, but there is nothing special about the file.

object styles.dyn (28.5 KB)

Hi,

It is working perfectly fine on my side in a test file with the longest lacing and without list levels.


image

You should also update the Genius Loci package to the latest version.
object styles V2.dyn (26.3 KB)

2 Likes

I just needed to download the latest version of the package and replace the nodes. Thank you for the help, I hadn’t realized a new version had been released.

1 Like

If I wanted to input several numbers to check for how would I do that? I tried creating several number nodes and turning that into a list, but that didn’t seem to work. Would list.contains work? The description implies a single item, not a list.

Example:
If the list has 1 or 2, change to 3
If the last has 1, 2, 3, 4, change to 5

You need to write a conditional statement.
The easier is to use the Design Script language. Search “conditional statement” in the forum to find examples.

2 Likes

Thanks