Import information from Excel file and copy it into Revit parameter

Hello,
I was wondering if someone could help me with my Dynamo script. I’m a beginner about this and even the big help of this forum i can’t do what i would like to do…
My goal is to import information from an Excel file sheet (some of them) and copy them into differents Revit parameters.
Is someone see something wrong in my srcipt?
Sincerrely,

Romain
HVAC engineer and BIM Coordinator

@r.machicot

Project Adress in the Project Information is a multi line text field
You need to give it just one item. not 5
something like this

Element of category have to connect to Element.Setparameter, no from Element.Getparameter

1 Like

Thank you very much! I understand better how it works! However, do you know how from my GetItemAtIndex node i can tell : this excel info (COGEDIM for exmple) will be copy to this REVIT parameter then this one to this one and so on…?
@m.rijsmus i didn’t understand the multi line text. i did a try with a multi text into an Excel cell and the copy xas good into Revit (into a shared parameter i created). The text appears with several lines like i wrote it into Excel.

multiply the SetParameterByName node for each Revit parameter i want to give information? But how sort the right information for the right parameter?

In the string node press Enter

@m.rijsmus I’m sorry Marcel, I’m too novice to understand this.
1- is it for copying several Excel cells into several Revit parameter?
2- my code block node doesn’t have an enter link (lst) like you have

in the codeblock just type lst[0][1]
the lst input will created (lst is just for list, it could be x or n or anything, well not everything :slight_smile: )
[0][1] means, get the first item in the list of lists (nested list)
DesignScriptDocumentation.pdf (705.5 KB)
DesignScriptGuide.pdf (3.7 MB)

1 Like

Thank you Marcel for your time and those guides. I used your code block to select specific information from my Excel file but i get only one letter. So for example into my Revit file i have only the B (first letter) of “Belvedere” which is the project name… Do you know how to get the entire cell?

Just remove the second [0]

Use list[0] instead

1 Like

List is not a nested list which you can get by using [0]

List
–List
is a list, within a list, nested one level deep, which you can get by using [0][0]

if you click the > on a node and activate “use Levels” you can do things like this

To @m.rijsmus point you should start by reading the Primer (We all did).
http://primer.dynamobim.org/en/
To understand list levels in particular try and read this:
http://dynamobim.org/introducing-listlevel-working-with-lists-made-easier/

2 Likes

Thanks to all of you. I could create what i needed to do. Script execution is succesfull!
Yes of course I will need to read all of those guides, and I want to, but with work and the need to produce, unfortunately sometimes it’s complicated. That’s why I asked you so much!

Hello friend, good afternoon, reading your post, I think I found myself in the same situation a few years ago, I need to load information from an excel to some project parameters. I don’t know if you can help me, thank you. @r.machicot