DotNetGetInt Function

Action

Gets the integer return value of the last DotNetCallMethod call in nReturn.

Include file

DotNetAPI.bdh

Syntax

DotNetGetInt( in    hObject : number,
              inout nReturn : number ): boolean;

Return value

  • true if successful

  • false otherwise

Parameter Description
hObject Handle to a .NET Object
nReturn Integer variable that will receive the return value of the last DotNetCallMethod call

Example

dcltrans
  transaction TMain
  var
    hObject, hObject2 : number;
    nReturn           : number;
  begin
    DotNetSetString(hObject, "ConstrValue1");

    hObject := DotNetLoadObject("bin\\Release\\MyDotNet.dll", "MyDotNet.TestClass");
    hObject2 := DotNetLoadObject("bin\\Release\\MyDotNet.dll", "MyDotNet.ParamClass");
    DotNetSetFloat(hObject, 1.23);
    DotNetSetInt(hObject, 123);
    DotNetSetBool(hObject, false);
    DotNetSetObject(hObject, hObject2);
    DotNetCallMethod(hObject,"TestMethod");
    DotNetGetInt(hObject, nReturn);
    DotNetFreeObject(hObject);
    DotNetFreeObject(hObject2);
  end TMain;