DictTable.callObject Method

Calls the specified object method for a table.


public anytype callObject(
    str methodName, 
    Common Called, 

Run On



  • methodName
    Type: str
    The name of the object method to call.
  • Called
    Type: Common Table
    The object to call. This parameter could be created by a call to the makeRecord method.
  • Type: [T:]

Return Value

Type: anytype
The results of the call to the methodName parameter.


If an attacker can control input to the callObject method, a security risk exists. Therefore, this method runs under Code Access Security. Calls to this method on the server require permission from the ExecutePermission class. Make sure that the user has development privileges by setting the security key to SysDevelopment on the control that calls this method.


This example calls the SysUserLog.onlineTime static method in the SysUserLog table and then prints the value that is returned from the call.

    Dicttable         dictTable; 
    int               onlineTime; 
    Common            common; 
    str               resultOutput; 
    ExecutePermission perm; 
    perm = new ExecutePermission(); 
    dictTable= new DictTable(tablenum(SysUserLog)); 
    if (dictTable != null) 
        common = dictTable.makeRecord(); 
        // Grants permission to execute the 
        // DictTable.callObject method. DictTable.callObject runs 
        // under code access security. 
        onlineTime   = dictTable.callObject("onlineTime", common); 
        resultOutput = strfmt("User online time is %1", onlineTime); 
        print resultOutput; 
    // Close the code access permission scope. 

See Also

DictTable Class

DictTable.callStatic Method