Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Active-X created in C++ to expose a C library
Message
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00902136
Message ID:
00913171
Views:
20
>I had to leave this project alone for a while but am now back on it...
>
>How would I send a message to the ActiveX's window if its derived from cOleControl and has no window handle property ?
>
>Thanks !!!
>
>
>
>>Override the message handler for the ActiveX's window. Post a custom message to the handler using SendMessage to the handle this->m_hWnd
>>
>>I would love to help more but the implementation can be rather extensive.

Create a class derived from Cwnd. have a member variable of that class the same as your control. Set the pointer of your control to the member variable. Now that window class can call your events.

Now, create a member variable of that class in your control. Create the window at construction. Then pass the handle to the window to other threads. They post a message which in turn is handled by your windows class which then fires the events on your control via the pointer in which you set earlier.

It is rather confusing and complicated until you know it. Then it seems rather silly and simple. Still confusing. But simpler.

Good luck. Hopefully this helps you. It is about as good as i can get with the time i have.
Brian Seekford
Seekford Solutions, Inc.
http://www.SeekfordSolutions.com
Internet ActiveX Controls and .NET Class Libraries.
SMTP/S FTP POP3/S HTTP/S SNTP MIME PING WHOIS TRACEROUTE NNTP DNS MX
Base64, UUEncode, yEnc, MD5, SHA1, URL, Quoted-Printable.
Resizer and Tooltips
Email Verification and more. Check us out!
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform