none
c++builder6.0引用C#编写的dll? RRS feed

  • 问题

  •  HINSTANCE   DLLInst   =   NULL;
            if(NULL   ==   DLLInst)
            DLLInst   =   LoadLibrary( "ViewContorl.dll ");
            if   (DLLInst)
            {
                    UnLoadCode=(void (*)())GetProcAddress(DLLInst, "UnLoadCode@0");
                    if (UnLoadCode)
                    {
                            UnLoadCode();
                    }
                    else
                            ShowMessage( "不能取得函数UnLoadCode指针 ");
            }
            else
            ShowMessage( "加载ViewContorl.dll错误! ");
            FreeLibrary(DLLInst);

    改写成UnLoadCode=(void (_stdcall*)())GetProcAddress(DLLInst, "UnLoadCode@0");
    也报错:ShowMessage( "不能取得函数UnLoadCode指针 ");
     

    2011年9月13日 10:59

全部回复