如何在InstallShield中调用用 vc++ 编写的dll里的函数?

解决方案 »

  1.   

    sample code:
    szDllName = WINSYSDIR^"xxx.dll";
    UseDLL(szDllName);
                      ....//call function
    UnUseDLL(szDllName);
    //for more details ,see installshield helpfile
      

  2.   

    我的代码prototype INT dllToinstall.Test(void);
    szDllName ="E:\\tangprogram\\myvc\\dllToinstall\\Release\\dllToinstall.dll";
    UseDLL(szDllName);
    Test();
    UnUseDLL(szDllName);出错信息
    C:\Documents and Settings\Administrator\My Documents\MySetups\dlluser\setup.rul(63) : error C8079: 'prototype' : invalid statementC:\Documents and Settings\Administrator\My Documents\MySetups\dlluser\setup.rul(66) : error C8025: 'Test' : undefined identifier
      

  3.   

    in setup.rul you should declare first,my code
    // your DLL function prototypes
    prototype BOOL  setupapi.SetupCopyOEMInfA(STRING    
     ,LPSTR 
    ,NUMBER,NUMBER,LPSTR 
    ,NUMBER,NUMBER,POINTER 
    );