Place new family instance each run

Oh ok maybe I understood. Correct me if I am wrong:
You have a list of n coordinates on which to place objects.
At some time you have to add elements, so you will have n+m elements.
You would like to run the script with all the n+m elements? If this is the case it’s best if you just run it for the new m elements.

Yes, that’s almost right:
I have list of n elements with coordinates, levels, parameter values, etc that I need to place in the Revit model. I run the script and place the elements.
Some time later I find out that I need to place additional list of m elements. So I would like to run the script again for the m elements only, without disturbing previously placed n elements.

Note that by then previous n elements might have already been edited a bit in Revit, so it wouldn’t be a good idea to delete them and place them anew together with m elements.

So I guess you should simply run a script and place the n elements, then after some time you will re-open your script, change some inputs to load only the m info and place corresponding elements.

There will be problems if I save the script after placing n elements, because the script will ‘remember’ those elements.
Later, even if I change input coordinates, the script will first move around the n elements and only when n elements run out (if the m element count is greater) will add additional m elements.

If I need to save the script after placing n elements, It seems that I need to open an empty placeholder Revit file and run the script to reassign the “element-memory” and save the script again.

Only then I will be able to place new m elements in the original rtv file without disturbing the n elements.

Could you post an image of your script? Dynamo shouldn’t behave like you’re saying, i.e. once you close and reopen the script, let alone Revit itself, it shouldn’t remember the last run

It “works” like that for the original script shown in the post image.
Just try it.
Run the script, save it, close it. Observe the placed element.
Then. Reopen the script, change some coordinate value and try to run it again.
It doesn’t place a new element, instead it moves around previously placed one.
Note sure what exactly resets it. Might be possible if some nodes are deleted and then re-inserted.

I’m running Revit 2016 with Dynamo 1.2.
Here’s the dyn file:
ExcelToRevit_v5_placeElements.dyn (8.3 KB)

I apologize, you are correct, I just tried it myself and it works as you say, while just some time ago it worked correctly. I tried it with some older versions of dynamo and the close/reopen trick worked. Don’t know why it’s happening ):

Thanks! Just out of curiosity, what versions of Dynamo did you try?
Maybe I can switch.

I tried with both 1.1 and 0.9.1 and the trick works.
Maybe someone knows why this is happening

After posting in github about this, I was told that this actually works as intended. I hope they will add a feature to break these links as well.

I think the link between Dynamo and Revit is stored in the dyn file if you save it after the first time you run it. Try to reopen the script without saving and see if that helps.

@Emi @GregX @Einar_Raknes I solved this before to one of the user. I will post soon the result.


… if you want to break this manually, you can delete the node serialization data inside the .dyn file… it will look like a bunch of random letters and numbers. tread carefully.

1 Like

I’ll be looking forward to that. Thanks in advance.

@Emi @GregX There are some custom nodes that places family instances in each run. One of the possible way is to use “FamilyInstanceByPointinTrasaction” from Bakery package.


Another option is to use clockwork copytolevel to save copies of each instance.

Hi @Michael_Kirschner Could you please show where can i find node serialization data inside dyn file. Thanks :slight_smile:

It’s as shown below if I’m not mistaken. If you delete this you can open the .dyn file in dynamo and run again without deleting the previously created geometry. But then you have run it again and new trace data have been created.

Thanks @jostein_olsen I tried to remove and run the dyn file. It doesn’t work :frowning:

Hello @Kulkul!

I am trying to use this node to allow me to place several hanger instance along a pipe, reading rotation, elevation and other parameters and writing onto the new instances.

Now the “FamilyInstanceByPointinTrasaction” works for one instance per run?

What can I modify in the script to make it work for multiple instances?




1 Like