这是C#写的dll 
using System; 
using System.Collections.Generic; 
using System.Linq; 
using System.Text; namespace Dlltest 

    public class DllClass 
    { 
        public int add(int a, int b) 
        { 
            return a * b; 
        } 
    
    } 
  

现在我要在delphi中调用DllClass类的add方法,什么调用

解决方案 »

  1.   

    静态调用或者动态调用,external 你的dll,然后调用函数
      

  2.   

    function abc(icdev: longint;offset:smallint;length:smallint;data1:pchar):smallint;stdcall;
    far;external 'abc.dll'name 'abc';
      

  3.   

    这类dll是不能象标准dll那样值接调用的
      

  4.   

    C#的dll默认是托管的,格式跟win32的dll不一样,没法直接用,而且win32下dll不支持导出类型,
    非要这么用的话,可以用Delphi调用C#编写COM+的非托管dll