Python - Elevation Marker is UnknownElement

I’m trying to pass an elevation marker to Python in order to create additional elevations from an existing marker but when I do it fails because Python says the element is an “UnknownElement”.

The weird thing is I’m upgrading this graph from Dynamo 1.3 to 2.0 and it used to work fine in 1.3. Both on Revit 2019. Is there anything I’m doing wrong? I’ve tried to strip the Python back to the bare minimum I’d need.

Hello.

When you are using API to affect objects in Dynamo, you need to unwrap the element first. You can read about wrapping and unwrapping here: https://github.com/DynamoDS/Dynamo/wiki/Python-0.6.3-to-0.7.x-Migration down in wrapping and unwrapping section.

Replace line 22 with marker = UnwrapElement(IN[0]) and line 23 with planView = UnwrapElement(IN[1]) and it should work, or at least move on to the next error if there are any.

Thank you, I think I was running myself around in circles trying to solve too many issues at once!