Code: Select all
user := (User.number.String & "." & id.String).asObject.User;
Code: Select all
user := (User.number.String & "." & id.String).asObject.User;
Be careful of code like this if your system ever gets to the point where it needs to use the extended class number range for some of your classes. Instances of the extended class number range classes are not correctly handled by the "oid" versions of these methods and you should instead use the "object" versions of these methods. ie:I'd just use String::asOid, e.g.
"2216.35".asOid().inspect();
Return to “General Discussion”
Users browsing this forum: No registered users and 13 guests