Node: 'Element Types' problem with Revit 2019 in comparising with Revit 2018


#1

Hello Everyone,

I made a Dynamo-script for exporting Schedules to Excel.
There for I also used the Standard Node ‘Element Types’.
The Dynamo-script and this node (Element Types) works fine for Revit 2018, but when I use the same dynamo-script for Revit 2019, things go wrong…

image
(Revit 2018)

It looks like Revit 2019 has more ‘Element types’, because the ‘element types’ Node displays not te same element type in comparising with Revit 2018. For Example: Instead of ‘ViewSchedule’ it displays ‘ViewFamilyType’.

Has anyone got a solution for this problem?


#2

I believe this is because there are new element types in 2019 which didn’t exist in 2018, messing with the index.

Try using a string or otherwise calling them by name as an alternative.


#3

Thank you for your comment.

Unfortunately a ‘String’ or ‘Code Block’ as a String doesn’t work.
Is there also a Node ‘by name’ for Element type? Because I can’t find something like that.

I found a solution, but it is a little bit weird to add al those Nodes only for Revit 2019:


#4

I have also used Clockwork and either Get Item at Index (Document.ElementTypes has a sort node) or the string search to define the Element Type I needed.

A more robust version of this would be useful OOTB. Like the Category by Name as f.land mentioned.

Or at least as a Code Block? Anyone (@JacobSmall or similarly knowledgeable) know how we might define that?

Cheers


#5

Element type by name doesn’t scale vary well, because there are too many element type options and there is a near certainty of an overlapping name. Pulling the ‘first’ or “every matching” type by name is going to cause a lot of misses. Note that the ‘family type by name’ node in Rhythm goes with the first method, which works fine unless you want the window that is 30x84 and the door which was 30x84 was added to the job first.

For this reason, I’d narrow your search a bit, which Dynamo has already accommodated (in the case above anyway).

A datashapes powered UI which allows selection of the type after an initial selection of the category/family/whatever is another option as well (Note that family.byname can’t overlap :slight_smile: ).