views:

37

answers:

0

I have a class based on CSocket in a DLL which has various threaded buffers for holding the incoming stream. I have a couple of applications with which this works perfectly, using a timer to poll the buffer to see if anything is there to be pulled out and then displayed.

Now I've got the timer in some VBA code, a macro if you will, in an Excel module. The timer fires as expected but the DLL only says there's stuff in the buffer when you hold the mouse button down on a scroll tab or the title bar of Excel! So if you try moving the Excel window the table starts populating with data pulled from the buffer. If you try moving the window programmatically then it doesn't work. Somehow mouse focus has to be on the frame of the Excel window. It also works if you open the system menu at the top left of the window. (This is Excel 2003 SP3 BTW.)