【发布时间】:2014-07-31 21:43:59
【问题描述】:
puplic class Example;
{
public static int Test(int[] Array, int value1, int value2)
{
// here I calculate my value1 and value2 by using my Array
}
}
上面是我的dll。然后我想在下面的 Windows 应用程序中调用我的 dll。
private void buttonStart_click(object sender, EventArgs e)
{
int value1=0, value2=0;
Example.Test(Array,value1,value2);
}
我的数组是全局定义的。在我的 windows 应用程序中,我想调用我的 dll 并在 dll 中计算我的新 value1 和 value2 然后将 windows 应用程序中的 value1 和 value2 更改为新的 value1 和 value2。
我是使用 dll 的新手。我可以使用 'return value1;' 从我的 dll 中返回一个值但我不知道如何从我的 dll 中获取两个值。
有人知道路吗?
【问题讨论】:
-
你想通过引用传递吗?
标签: c# dll windows-applications