Link to home
Start Free TrialLog in
Avatar of abulka
abulka

asked on

calling dlls from activex - ok to do?

Is it OK to call a dll from within an activeX (built with vc++).  Is there anything to watch out for, or anything unusual that I need to watch out for?  Is it exactly the same as calling a dll from a regular window app?

PS. I plan to build my dll using delphi 4 and declare the functions 'stdcall' calling convention.  And I plan to use LoadLibrary and GetProcAddress from within the VC++ active X.

e.g.
    HINSTANCE hDLL;
    FARPROC ProcAdd;

    hDLL = LoadLibrary("a1.dll");
    ProcAdd = GetProcAddress(hDLL,"ANDY0");
    if (ProcAdd == NULL) return 0;
    ProcAdd;    // call to dll

ASKER CERTIFIED SOLUTION
Avatar of jhance
jhance

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of abulka
abulka

ASKER

Ok thanks - I just thought that there might be some complications due to memory movement / address spaces etc.  Good to hear its ok.