In X# you can use a conditional access to an object.
Instead of writing
if oObject != null oObject:ExecuteMethod() endif
you can write
This means that there will be no exception in the case oObject is null. Of course this works not only with methods, but also with properties (and access/assigns):
oObject?:MyValue := cMyValue