UI.MultipleInputForm ++

Those who have paid attention to my previous post might have noticed that there was a new Form creation node in the Data-Shapes package called “UI.MultipleInputForm++” .

Edit: all the forms of the Data-Shapes Package now handle all screen resolution. 

The UI.MultipleInputForm++ node may have the exact same purpose as the previous UI.MultipleInputForm (which still works like this), but it allows more customization and offers the possibility to use ListView inputs. Here’s how it works :

What is new :

This new node has more inputs than UI.MultipleInputForm :


let’s go through the function of each input :

  • Description input (optional): the description input allows to add a description of what the workflow does at to top of the form :


The description is optional, in case you don’t add any input it will create a form without a header:


  • The Logo input (optional): This input allows to add your personnal logo at the bottom left of the form. The input must be an image. You don’t have to worry about the resolution or the size of your logo, the code has been made in such way that it will be automatically resized. You can obtain image inputs using filepath, File.FromPath and Image.ReadFromFile nodes. Your custon logo will also be converted to an icon and override the window icon :


The logo input is optional. In case you don’t add an image input, you’ll see the default Data-Shapes logo.

  • Button Text input (optional): UI.MultipleFormInput++ is all about customization! The “ButtonText” input allows you to change the text on the Form validation button:


This input is optional too and the default ButtonText value is “Set Values”.

The inputs:

UI.MultipleInputForm++ has a very different way to take inputs than UI.MultipleInputForm. Setting the user inputs asks for a little more work but it allows more flexibility and, once again, costumization. Let’s go through all the types of input:

  • TextBox input: In order to add a textbox input the form, you need to use the “UI.TextBox Data” node. This new method of creation allows to set the text box label and also the default value :


In case you don’t specify an InputName and DefaultText, a generic TextBox will be created :


  • Boolean input : Boolean inputs can be added in a similar way, using the           “UI.Boolean Data” node. Here too you can set the InputName and Default Value, or create a generic boolean input:


  • Filepath and DirectoryPath inputs : You will need “UI.FilePath Data” and “UI.DirectoryPath Data” nodes to add FilePaths and DirectoryPaths to the form. Once again you can customize the input label and also the default value if you want to:


In case you don’t enter default values, the buttons will read “FilePath” and “DirectoryPath”.

  • Revit selection inputs : For those types of input, you’ll need “UI.SelectModelElements Data”, “UI.SelectFaces Data” and “UI.SelectEdges Data” nodes. You can set the input label and the text that will be written on the buttons. If you don’t specify anything, generic texts (“Input”, “Select Face(s)”…) will be used.


  • Color selection input – Only with Revit 2017In order to add a color selection input to the form, you need to use UI.ColorSelection Data. — This input was inspired by Adrien_P’s comment on my previous post, which I think is great. This kind of interaction is really what I intended this blog to be about.– It uses the same method as Rhythm’s UI.ColorPicker by John Pierson. It calls the UI colors selection interface directly from a form button. Here too you can specify the label and button texts :


The form outputs a revit colour so, in case you need it, you can use Clockwork’s RevitColor.ToDynamoColor to convert it:


When used with Revit 2016 or previous version, you’ll get this message if you try and add a ColorInput :


  • DropDown and ListView inputs: These are created with “UI.DropDown Data” and “UI.ListView Data” nodes. The “Keys” are the elements that will be shown to the user, and the “Values” are the elements that will be returned accordingly to the keys. The keys must be strings ! The UI.ListView Data node allows you to set the height of the list window (notice the difference of list windows height in the following image):


  • TextNote : This input has been inspired by Micah (@kraftwerk15). It allows to add a textual note to the form. You can also add a title for the note (optional):



I hope this will further help people adopt dynamo workflows in your workplaces !

Here’s the code of this node:

30 thoughts on “UI.MultipleInputForm ++

  1. I just had my first chance to try these out and using the dropdown node with lists I get “IronPython.Runtime.List” showing up in the userform dropdown instead of my list of keys. Any thoughts on what I’m doing wrong? Thanks.


  2. When I tried the “Revit selection inputs” I get the window as shown and it let me select the elements but when I try to select the faces I get an error messages:
    “Unhandled exception has occured in your application. If you click Continue, the application will ignore this error and attempt to continue. “


    1. Hi Cesare,
      After checking the revit API, it turns out ColorSelectionDialog is only exposed since Revit 2017:

      Thanks for pointing this out!! I fixed it so it doesn’t keep the form from working with previous revit versions. It will just let you know that the ColorSelection input is only available for Revit 2017. You can upload the package to version 2017.01.03 . Please let me know if it runs well.


    1. I thought the same. It can be solved by changing the python code:
      Adding the following to ‘from System.Windows.Forms import’ – “, ColumnHeaderAutoResizeStyle, ColumnHeaderStyle”

      and After line 185 ‘ ‘
      replace ‘lv.View = vi.List’ with ‘lv.View = vi.Details’

      Before the line ‘[lv.Items.Add(i) for i in j.keys() if not (i == ‘inputname’ or i == ‘height’)]’ add the lines ‘lv.Columns.Add(“Data”, 160)’ and ‘lv.HeaderStyle = ColumnHeaderStyle.None’

      After the line ‘[lv.Items.Add(i) for i in j.keys() if not (i == ‘inputname’ or i == ‘height’)]’ add the line ‘lv.AutoResizeColumns(ColumnHeaderAutoResizeStyle.ColumnContent)’

      That should get you a vertical list and horizontal scrollbars if the content is too wide to fit in th listbox.


  3. What a great improvement!

    Furthermore, I saw that there was added an integer slider to the newest update of the package – is there any way to insert a ‘step-value’ for this slider? I haven’t been succesful in doing so.

    With kind regards


  4. I can’t get the player to run my routine over and over and over again.
    “Traceback (most recent call last): File “”, line 474, in Indexerror: index out of range: 0″

    Any clues?


  5. Geart work !

    i was trying to duplicate the example “DropDown and ListView inputs” from above. i get the drop down menues as sh0wn, but the only problem ist that the categories names appear as “Autodesk.Revit.DB.Categories” instead of showing the real name of the category, i tried to figure it out but could not get the reason behind it.


  6. are your dialogue boxes able to be active…most of the time I use them it is for a single-function input. I would like to have a UI while running in Automatic mode.


  7. I am having an Issue where I cannot get the last example to work with two inputs, I can only run one input at a time, but when I combine them in a list, only the TextNote Data input comes through.

    Liked by 1 person

  8. Thanks for your reply. I was actually able to resolve my issue. When using the ‘List Create’ node in my program, the resulting list had to be flattened for the UI node to recognize both inputs. I am not sure if my ‘List Create” is different than your List.Create but adding a List.Flatten to the output worked for me.


  9. Hi
    First of all thank you for developing this package, It is increible useful.
    I’m having a problem with the selection element input. I select all the elemens that I want but it doesn’t let me to set the values and continue. I mean, the set values is blocked.
    Thank you


  10. Hi
    Thank you for developing this, It is amazing.
    I’m having a problem with changing the colors input. I am using Revit 2020. It is not working i select and then run but nothing happens
    Thank you


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.