When traversing the database it is often necessary to check whether an object exists.
For example when traversing layout objects to find which is a subcircuit I do:
which fails because some drawing objects don't have elements so what I actually need to do is:
A subtlety here: it would seem clearer to say "If obj.Element Is Not Nothing" but this won't work. The "obj.Element Is Nothing" must be one clause.