KitchenDraw SDK 2
Show / Hide Table of Contents

Method PluginCall

PluginCall(string, string, string, object)

Calls from the currently running plugin a method in another plugin (providing that it is developed with .NET technology).

Declaration
public object PluginCall(string dllName, string className, string methodName, object parameters)
Parameters
Type Name Description
string dllName

The name of the plugin .DLL file (with or without path, with or without the .DLL extension) in which the called plugin method is located.

string className

The name of the class of the called plugin method with a namespace.

string methodName

The name of the called plugin method.

object parameters

Parameter(s) that are passed to a plugin method. This can be eigher parameter of a system type (e.g. bool, int, string) or an array of objects of a system type.

Returns
Type Description
object

The object returned by the called plugin function. The return is null if the called plugin function is of type void.

Examples

Calling a method of another plugin.

var appli = new ActiveXObject("KD.SDK.Appli");
var params = new Array();

// string
params[0] = "str0";
params[1] = "str1";
params[2] = "str2";

// double
params[3] = 0.1;
params[4] = 1.1;
params[5] = 2.2;

// int
params[6] = 0;
params[7] = 1;
params[8] = 2;

// bool
params[9] = true;
params[10] = false;

var call = appli.PluginCall("KD.Plugin.Properties", "Plugin", 
                                "ShowArticleProperties", params);</code></pre>
In this article
Back to top Generated by DocFX