Code: Select all
vars
currOid : String;
jadeSkin : JadeSkin;
begin
currOid := "525.1"; //This is an invalid oid.
jadeSkin := currOid.asOid().JadeSkin;
if not app.isValidObject(jadeSkin) then
write "**INVALID OBJECT**";
endif;
if jadeSkin <> null then
write "but this is also not null????";
endif;
end;
So, if you have any code that is just doing a null check after an asOid this is pointless because there is always going to be an object after using the asOid method, whether it is valid or not is the only check you should be doing.
I feel as though this is a fault but would be interested to know if others agree before I log this in Parsys.