Adding methods

To call a method on an IDO extension class, the method must be declared as public and it must also be defined in the IDO metadata as a hand-coded method.

A hand-coded method can be either a standard method, which is a Function with zero or more input/output parameters and returns an integer; or a custom load method, which is a Function with zero or more parameters and returns an instance of either an IDataReader or a DataTable. For information about these, see the .NET Framework documentation.

When implementing a hand-coded method that is callable through the IDO runtime, you could add the optional IDOMethod attribute, which can be used in the future to facilitate adding the necessary IDO metadata to make the method accessible.

Sample standard method call

For example, the declaration of a standard method might look like this Function declaration:

[IDOMethod(MethodFlags.None, "Infobar")] 
public int DoWork(string SessionID, long TransNum, ref string Infobar) 
{ 
   // ...Implementation goes here... 
}