FloorPlan.ByRoom not working

The archilab node FloorPlan.ByRoom gives this error:

[0] Traceback (most recent call last):
File “”, line 95, in
Exception: The ElementId levelId does not correspond to a Level.
Parameter name: levelId<<

Any idea why?

It’s Revit 19 and Dynamo 2.0.3

The Archilab script python bit that seems not to be working is:

image

Hello,
you collect rooms in the current document or from a linked model?

From a linked model.

This is the reason for the error the Ids belong to the linked model not to the host model

Ah. Is there a workaround?

for each room

  • find the corresponding level in the host model (with elevation)
  • create a ViewPlan with this level
  • adjust the new ViewPlan limits according to the room’s bounding box (cropbox)
  • name the view
3 Likes

Hi,
I was having the same issue, with the exception that i did get it to work and then it stopped working.
I am handling 2300+ rooms from 5+ linked files, so I needed to make i work again.

The traceback showed me both line 95 and line 86 as errors. Did not figure out why it showed line 86:
Just for the record line 86 is:

newBbox = OffsetBBox(bbox, bboxOffset)

The fix was both making sure that all my levels in the linked files and the current model had the same name and then changing the level of the list with the rooms i was using:

It did still show me three errors, which are due to the fact that that linked model did not get its level names updated correctly.
As I understand it, with the level set to @L1 the node runs for each room, meaning it would fail for each room if those did not have corresponding level names (I am not an expert and still learning :stuck_out_tongue:).

Hope this helps.