Passing C++ thread data to Vb thru callback

H

hemoji

Hi,

I'm developing a win32 dll in VC++, I have a thread running
continuously in the dll to check for some input on socket, once it
finds a input the data is required to be passed to the VB app in 2
different modes based on requirement,
1. Send Windows message
2. Function callback

Send Windows message is implemented with no problem, but I'm struggling
to figure out how to invoke this callback function in vb from C++ dll,
I tried with normal callback with simple dll and vb app it works fine,
since my module is in a different thread, the callback happens to vb
(checked in debug mode) then vb runtime throws an exception 'access
voilation'.

I'm new to c++ environment, I'm a vb guy.

Experts pls suggest me a soln.

Thanks
Tenali
 
J

Jack Klein

Hi,

I'm developing a win32 dll in VC++, I have a thread running
continuously in the dll to check for some input on socket, once it
finds a input the data is required to be passed to the VB app in 2
different modes based on requirement,
1. Send Windows message
2. Function callback

Send Windows message is implemented with no problem, but I'm struggling
to figure out how to invoke this callback function in vb from C++ dll,
I tried with normal callback with simple dll and vb app it works fine,
since my module is in a different thread, the callback happens to vb
(checked in debug mode) then vb runtime throws an exception 'access
voilation'.

I'm new to c++ environment, I'm a vb guy.

Experts pls suggest me a soln.

Completely off-topic here.

Try
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,020
Latest member
GenesisGai

Latest Threads

Top