Count Wall Types to Excel

Hello,

I have a small thing i couldn’t figure out. I have made a Node that Looks for all the drawn wall types and export that into Excel. That is working great. But i like to add a row in excel that counts totals of the drawn walls.


So the result in excel is:

Capture3

Is this possible?

Thanks

Is it just the 2 2 1 you want to write down?
Also: could you show what your data currently looks like via a watch node or something.

How about using List.CountOccurences from Clockwork:

1 Like

Yes and when you draw a new test wall the number gets 3, So it counts the drawn types.

Capture4

Currently it only counts the amount of unique items there are. @Jonathan.Olesen’s solution should work.

Out of curiosity, since I can’t try it ATM, would groupbykey work with the same input as list and key, then a count?

That would work too:
image

3 Likes

That’s probably the better option as no packages are needed.

1 Like

Thanks,

With join and combine i got the results i want in Excel

This the code:

Last question about this when you want to add more data to the excel sheet. For example base constraint, material etc. so you can make a material list. I thought you can do it the same with combine and join. But you get an other result in Excel

Looks like the fact that you have only one type of base constraint?
Also, try using list.create instead of list.join and list.combine.

1 Like

Hi,

I have changed it to list.create and after that a list.transpose. So thanks!

Maybe i can better explain my wish with an example of Mark values. Normally in Revit schedules it can split values also by other parameters so in the picture below for example by a different Mark. Is it possible dynamo can do this? and when the all the marks of Wall 2 are B you only have to rows.

Capture8

It would save me so much time :slight_smile:

Have a look into what keys you’re grouping by :slight_smile:

1 Like

Solved :smiley:

I begin to understand how Dynamo is thinking. So thanks for your help!

Hi,

When i tried the code on Structural Columns i want to have the type name.

But it shows in Excel: “Family Type: 200UB25.4” So i don’t want to see “Family name” in front of it only 20UB25.4. Why is this happening?


Capture10

Hi Vanlion, this is in fact a different issue and should be kept in a different thread, however try using ''familytype.name after you query for name parameter.

And if a comment solves your problem then mark that as solved, to make it easier for other users, and maybe leave a like here and there.

1 Like

Hi Vanlion
I couldn’t help myself. As you see below you can simply use “FamilyType.Name” directly on your “All Elements of Category” to get all the Family Types (Thus simplifying your graph a little).

1 Like

Thanks :+1:t2:

I Will try is t this weekend by myself.