Modify Phyton Scripts

I have this rhythm package nodes that i want to modify the python but i have no idea how to do python.

  1. Pick Model Element
  2. Isolated Pick Model Elements (ordered)

In the Pick Model Element, you pick the elements you want and click the FINISH button when done.
In the Isolated Pick Model Elements, you pick the elements you want and hit the ESC key and the selected elements are in ordered on how you pick them.

My problem is i want to use the Isolated Pick Model Elements but i don’t want the hit ESC…instead i want to incorporate the click FINISH when done.
Can somebody help me with this?

attached are the python codes for both nodes.

Isolated Pick Model Elements_Ordered.txt (1.3 KB)
Pick Model Elements.txt (845 Bytes)

You will find what you need to get started in this thread:

You can then post here what you tried this way:

If i understand your question correctly, I’m pretty sure that none of the links that @Yna_Db provides will give you an answer. We are not able to modify the Finish-button in Revit. Maybe you can create custom dialog with a finish button. Take a look at the nodes from DataShapes.

2 Likes

hi @Einar_Raknes, thanks for the relevant reply.

I have included the screenshots for the Pick Model Elements as well as the output.clean.

I am not sure about the DataShapes though…

Hi @Einar_Raknes I am not trying to modify the Finish Button. Currently I am using the Isolate Pick Model Elements (ordered) node. You select something and hit ESC key.

The Pick model Elements which uses the Finish button is much better but it doesn’t select ByOrder and doesn’t have the Category input in its python code.

If possible I want to modify the Pick Model Elements node, add a Categories input into it and use the Finish button instead of hitting the ESC key.

Ok, that is not possible because we are limited by the Revit API. It is probably possible to make a Form/DialogBox with your own finish-button if you don’t like to press ESC.