Quantcast
Channel: Scripting - McNeel Forum
Viewing all articles
Browse latest Browse all 5938

IsolateLockToggle does work only at the second try now

$
0
0

Hello,

can someone tell me why this happens most of the time and how to change the code?

Thank you

The Error:

The Code:
import rhinoscriptsyntax as rs
import scriptcontext as sc

x = False
if sc.sticky.has_key (“IsolateLockState”):
x = sc.sticky[“IsolateLockState”]

if x:
rs.Command("UnIsolateLock Enter ")
sc.sticky[“IsolateLockState”] = False
else:
rs.Command("IsolateLock Enter ")
sc.sticky[“IsolateLockState”] = True

IsolateLockToggle.py (333 Bytes)

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 5938

Trending Articles