|
-
May 23rd, 2009, 09:50 AM
#1
Thread Starter
New Member
Monitoring : call of a VC++ DLL in a VB2008 EXE
Hi all,
I try to make a monitoring tool with vb2008 and a VC++ DLL (I wrote).
But : I don't no either VC++, or VB2008, and DLL conception !
But I know VB5 and I started from a 100% (DLL and EXE) VC++ solution, which I compiled and ran successfully. Then I adapted the DLL to my own needs and built a small VB2008 EXE.
I will surely meet lots of trouble to succeed in running this program. But now I have a trouble with this message : "EntryPointNotFoundException". Is there a trouble in the DLL or in the EXE ?
Here are extracts from my code. First the .h from the VC++ DLL :
#define MONITORING_API __declspec ( dllexport )
extern "C" MONITORING_API bool installerLeMonitoring(LPCWSTR cheminDuClient, HWND hFenetre, PROCESSUS_A_MONITORER** ppProcessus, int nombreDeProcessus);
extern "C" MONITORING_API void desinstallerLeMonitoring();
And now the call from the VB2008 EXE :
Imports System.Runtime.InteropServices
PrivateDeclareAutoFunction installerLeMonitoring Lib"D:\Developpements\opb\bin\monitoring.dll" (ByRef cheminDuClient AsString, ByVal hFenetre AsInteger, ByVal ppProcessus() As ProcessusAMonitorer, ByVal nombreDeProcessus AsInteger) AsBoolean
PrivateDeclareAutoSub desinstallerLeMonitoring Lib"D:\Developpements\opb\bin\monitoring.dll" ()
(...)
installerLeMonitoring(Application.ExecutablePath, frmPrincipale.Handle(), processus, nombreDeProcessus)
If someone can help me to solve this trouble...
Most generaly, the DLL spy calls to API like DrawText or CreateFile and transmit these informations to the VB2008 EXE. The EXE just has to print these informations in a TextBox for the moment ! If someone is interested in helping to debug the solution, no problem for me to share the entire source.
Regards,
Olivier
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|