close Embed map monkey?
I'm trying to embed map monkey into my front end written in vb6.
this is how i embed map monkey into a picturebox and that works great
but when i trying to exit map monkey whit this code it wont end, what are i doing wrong?
Do Until hProgramWnd
hProgramWnd = FindWindow(gpslpClassName, gpslpWindowName)
SetParent hProgramWnd, Form1.picGPS.hWnd
SendMessage hProgramWnd, WM_CLOSE, 0, 0
Don't know if it matters, but i use:
SendMessage seemed to have problems with certain messages.
PostMessage hwnd, WM_CLOSE, 0&, 0&
Also, you might want to call
to unembed the program.
SetParent hProgramWnd, 0&
If that doesn't work, make sure hProgramWnd has a value in it, and that WM_CLOSE = &H10.
There's also the CloseWindow API.