Creating Sheets and editing Sheet Parameters

Hi

I am not new to Dynamo, but I am still a beginner and learning a lot.

I am trying to write a script that creates sheets from an excel file containing the sheet number and name and then edit the Drawn by, Checked by, Approved by parameters, also read from the same excel file. I am following a script example from 2017, using the Excel.ReadFromFile node which I believe is no longer available. I am using the Data.ImportExcel node instead and noticed that the outputs are different.
Excel.ReadFromFile - var[][]
Data.ImportExcel - data

Further down the line my lists outputs are of type item, while the older script has list outputs of var[][].
When editing the sheet parameters with the Element.SetParameterByName node, I get the following error:

Warning: Element.SetParameterByName expects argument type(s) (Revit.Elements.Element, string, var), but was called with (Function, string, string[]).

My create sheets node, Sheet.ByNameNumberTitleBlockAndView returns the type Function, and not an Element and my list output of the parameter values read from my excel file is string[], instead of var.

I would like to understand why some nodes return the type Function and what it means and how to get it to return a type that can be used by connecting nodes? Any assistance will be greatly appreciated. Snips of my script are attached.


The last node in your create sheets group, Sheet.ByNameNumberTitleBlockAndView needs a view input for it to work, otherwise it will be in a function state and won’t actually create any new sheets. Provide a view (a simple legend would work) to pack and it should work out.

Thanks so much Jacob! That did the trick. However I found that this did not work when running the script after it had already been run. I had to close the script and the Revit file (without saving the changes) and then run the script for it to work after specifying the view.