I’ll try to explain my problem logical and short.
What does Script do: Script is coloring all the tags according to system they are attached.
Script is working fine until I Tag the attached reference file (Revit model). If I delete the referenced file the script is working as it should.
Maybe the problem lies in the script because it doesn’t know which model it should “color”.
Does anybody have any ideas how to solve the problem? Maybe with additional Add-on?
Thanks for all the help and suggestions.
I’m attaching/sharing working script.
0-Couleur Etiquettes.dyn (569.4 KB)
Can you post screenshots of your graph with and without the attached Revit file? Be sure you have node preview bubbles turned on so we can see what’s happening. As you suggested, it’s probably due to your graph not knowing how to handle multiple files.
Thanks Nick for the help.
Here are two screenshots of working and not working script.
Due to its size I’ve created a link to dowload the screenshots.
I’d suggest trying to post screenshots directly to the forums for a couple reasons. You’re likely to get more help if everything is available right here. Some people won’t want to download external files just to see what you’re doing for many reasons. Also, it’s much more helpful to other people who may come across your post weeks, months, or even years later looking for similar information. If they don’t have those files to download and look at it’s not very helpful.
Besides all that, your nodes are illegible. You have to be zoomed in enough to where the node titles are visible before taking any screenshots. It’s highly recommended you use the “export workspace” button in the top right of the Dynamo window to do this.
Yes I totaly agree with you. Ok I somehow managed to downsize the files so they can be posted within the reply.
First thing you need to do is fix your Tag Host Element node. It has an invalid input name. If you open the node it will describe the problem for you. If you’re still unsure on what to do you can check the forums for examples.
Still didn’t find the solution. I’ve changed the Tag host element node. Add node Document.ActiveViewFromCurrentDocument but still doesn’t work.
Need to find the node which will distinguish and eliminate all connected Revit file from process. Guys any idea where to look.
The script work fine for ducts, because I didn’t tag ducts in connected Revit file. On the contrary the pipes were taged in the connected file - the script is not affecting them.
I don’t need that the script work for connected Revit files it has to work only for active Revit file.
Thanks for the help.
Have you tried
Nope, I didn’t. Frankly I don’t know where to put it;)
What is interesting is that if I delete the referenced Revit file (file which I accidentely Tagged and because of that script cease to work) script works as it should.
if “abbreviation du systeme” is a project parameter it would make sense you are getting issues trying to read it from a linked model. Is the parameter you are querying a project param or a shared param?
It’s probably getting a null value from the linked model somewhere. Keep in mind that linked elements don’t have every method available to them that project elements do (API wise). Could you simply filter out tags that are host by linked elements?