Room Boundary Lines - Work Plane

Is there a possibility to read the workplane or the host level of the Room Separation lines ? For instance when there are multiple levels very close to each other and the Room Separation lines are placed in the respective levels, its hard to find them in the floor plans when not looked in to the right Level.

Hoping there should be a way to do this

See these maybe…

1 Like

Totally forgot about this problem. After digging few forums found that the every “Lines” category is drawn on Sketch Plane, so one could know the level of the “Room Separation” Lines using the “SketchPlane.Name” function.

roomLine = UnwrapElement(IN[0])
OUT = roomLine.SketchPlane.Name


can it be changed to another level? i tried w/ following but nothing happen
import clr
from Autodesk.Revit.DB import *
from System.Collections.Generic import *
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager

spaceLines = UnwrapElement(IN[0])
for i in spaceLines:
i.SketchPlane.Name = IN[1]

OUT = spaceLines

i tried i.SketchPlane = IN[1] in which new sketch plane based on new level is used for input, not working
i assume separator lines need to be recreated, isn’t it?

in fact, i did recreate separator lines but they are still old level based

can you post the image of your graph?

It’s hard to understand what you are trying to achieve. The SketchPlane and the name of it for the ModelLine and RoomSeparation Line could be done so:

if you want to change the plane of the lines you have to use SetSketchPlaneAndCurve method

thanks Raja, my problem is how to re-host room/space separation line from one level to another level?
i can set new sketch-plane for room/space separation line but it won’t necessarily associate to new level even though that new sketch-plane is based on new level, perhaps i missed something simple here?

hi Raja, i tried your method but didn’t work, SetSketchPlaneAndCurve will throw exception

doc = DocumentManager.Instance.CurrentDBDocument
spaceLines = UnwrapElement(IN[0])
x = “”
for i in spaceLines:
#i.SketchPlane = IN[1]
i.SetSketchPlaneAndCurve(In[1], i.GeometryCurve)
x = “oops”
OUT = spaceLines, x

Hi @Ning_Zhou,

As far as I know changing the SketchPlane of Room separation lines aren’t allowed.
Alternatively you could create the Room separation lines to new level from existing/reference curves using Clockwork package. You can refer to this link