Guid does not exist in LayerTable

Hi all,

I keep getting this issue which I can’t seem to fix. Is there some essential concept I’ve missed? Are the guids not always a property inherent to each object in the document?


objs = rs.AllObjects()

for i in objs:
    lay = rs.LayerName(i)

Try this.

import rhinoscriptsyntax as rs
layers = rs.LayerIds()
if layers:
    for layer in layers: print rs.LayerName(layer)


1 Like