Reporting Wall Types Builderswork are Intersecting


#1

Hello,

I am trying to report the wall types (from a linked model) the builderswork (generic models) are intersecting and add this to a text parameter in the revit model. I have tried to produce a dynamo script (attached) but I am receiving an error.

Warning: Element.SetParameterByName operation failed.
The best overloaded method match for ‘Revit.Elements.InternalUtilities.ElementUtils.SetParameterValue(Autodesk.Revit.DB.Parameter, double)’ has some invalid arguments

Please could anyone help!!

Many Thanks!


#2

It looks like your parameter is expecting a number. (double)
Can you make a test with a number or verify the storage type like in this thread ?


#3

Hi,

Thanks for your help. Test with storage type verified below


#4

You should do it like that to know the storage type.


#5

Sorry,

Revised Text Below


#6

So the parameter storage type of SMB check is a string.

You can obtain the type and convert it in string like this.


#7

Alban

I must still be doing something wrong!

Instead of the wall type being assigned to the “SMB Check” parameter the text “Type” is?

Thanks!


#8

You should use Element.GetParameterValueByName or Element.ElementType node instead of Parameter.ParameterByName node.


#9

That doesn’t seem to work either.

Thanks for your efforts


#10

You can replace the codeblock e.Name with the node “string from object”

Or you can convert the bimorph linkelements in elements. (There is a node for that in bimorph package)

And you can add a flatten node after the node BoundingBox.Intersect


#11

String from object worked.

Thanks for all your help.