Copy Titleblock from Linked model

I am trying to copied a titleblock on a selected sheet from a linked model, then place the selected titleblock to the active, which should be a sheet. I am not sure why the Spring Node ”Document.CopyfFromViewToView” keeps returning null.

That node was built in February of 2019 - it’s 8 years old now. In those 8 years there have been 7 new Revit versions, 27 Dynamo versions, 5 Python engines, and two .net versions… things are going to change over that timespan.

However I believe that the basic functionality still works - try copying a detail component in a drafting view in the active project to a new drafting view in the active project.

The likely issue is that the element you are working with is in a different project and as such may require a different node entirely.

Try working within the active document entirely to confirm.

Hi Jacob. The element I am trying to copy from the linked model is a titleblock family. If I understand correctly, titleblock has to be copied from a view to a view, and titleblock can only be placed on a sheet. I am not sure a titleblock family can be placed on a drafting view? Please correct me if I understand this wrong.

There are three things at play:

  1. Does the node work at all as it’s gotten too old or you’re missing a dependency
  2. Does the node work with a titleblock family as those are a bit unique as the view is odd
  3. Does the node work with a titleblock element from the link as that means you need to incorporate a second document and the method you call to shift the element over has to change as well to account for duplicate family name collision as well as the source of the data

As each of those is a step up in difficulty, I always recommend people start with the ‘easy’ version and scale up as if step 1 fails step 3 never will work.

Add in that the node doesn’t have any indication of the ‘source’ document to copy from, I’m leaning on that node not being built for your use case.

So, can you build a small sample that shows step 1 or 2 working?

@fangeunice

you could try this:

  • get the linked document
  • get the families from the link
  • filter out titleblock(s)
  • save the relevant family/families to a specific path
  • load rfa(s) into the host

Ouch, that’s quite the reminder of how fast things have progressed @jacob.small :zany_face:

given ADSK’s love of rebranding everything every couple of years, it’s amazing it is still called Dynamo…..

3 Likes

It’s amazing how much has happened over nearly 10 years of Dynamo!

@jacob.small

Thanks for your respond. I wrote a simple script and it appears the node is not working. Is there a possible workaround? Or another node I can use?

Looks like you’re passing a string into the sou8rce view input instead of a view. Can you move the AllElementsOfCategory node into the List.GetItemAtIndex node and see if that changes the result?

It’s still outputting null. Also attached the script as well as the screen shot.

script_test.dyn (27.3 KB)

This not working is indicating that the source node you’re using doesn’t work in this Dynamo version.

The options now are:

  1. Find an alternative package that works. This will require a good bit of research on your end - I am not aware of an option.
  2. Find an alternative package which used to work and modify it to work (i.e. this one). This will require some Python knowledge, and you’ll be taking on ownership of the modification and updates in perpetuity.
  3. Build a version with out of the box nodes. The newer Dynamo for Revit releases have tools for working with linked elements but I am not sure if your goal is attainable with them. This is likely the easiest today and into the future if it can be made to work.
  4. Script a solution using Python. This is kind of like option 2 but you’re starting from scratch.
  5. Build your own package to do the work. This opens C# based development which will be much more stable but has a higher knowledge requirement for entry.

Thanks again. I will continue to see if any other nodes will work. I do truly appreciate your help!