What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Skype & Technology » Skype & Live Messenger » StartVideo

StartVideo
Author: Message:
CMI
Junior Member
**


Posts: 17
Joined: Jul 2004
O.P. StartVideo
Has anyone been able to call StartVideo? I haven't been able to do it through IMessenger in a plug-in written in VB, or directly in VC++ 7. The method always returns S_OK, MSN Messenger opens an IM Window, but the invite isn't sent.

StartVoice works as expected, and I can send a video invite by clicking on the video button (which it does not appear I can fudge with through SendMessage as most of the IM window is just one big object...)

http://www.msnfanatic.com/forums/index.php?showtopic=9888&st=0&
07-10-2004 06:34 PM
Profile E-Mail PM Find Quote Report
Stigmata
Veteran Member
*****



Posts: 3520
Reputation: 45
21 / Other / Flag
Joined: Jul 2003
RE: StartVideo
code:
Private msn As MessengerAPI.Messenger

Private Sub Command1_Click()
msn.StartVideo "contact@hotmail.com"
End Sub

Private Sub Form_Load()
Private WithEvents msn As MessengerAPI.Messenger
End Sub

07-12-2004 10:14 AM
Profile PM Web Find Quote Report
CMI
Junior Member
**


Posts: 17
Joined: Jul 2004
O.P. RE: RE: StartVideo
quote:
Originally posted by jackass_wanabe
code:
Private msn As MessengerAPI.Messenger

Private Sub Command1_Click()
msn.StartVideo "contact@hotmail.com"
End Sub

Private Sub Form_Load()
Private WithEvents msn As MessengerAPI.Messenger
End Sub



I've tried that and it doesn't work.
07-12-2004 03:04 PM
Profile E-Mail PM Find Quote Report
CMI
Junior Member
**


Posts: 17
Joined: Jul 2004
O.P. RE: RE: StartVideo
quote:
Originally posted by TheBlasphemer
If you have the IMWindowClass HWND, you can send a WM_COMMAND,
To find out with what arguments, just open Spy++, log messages from IMWindowClass,
go in the menu -> actions -> Send my Webcam, and see what arguments WM_COMMAND had...

hope that helps, TB


Yes, this is my current solution, but I think its a bit sloppy. I thought that I must have just been doing something incorectly, but I recieve no errors and everyone suggests the same code I'm using. Its just plain weird.
07-12-2004 04:38 PM
Profile E-Mail PM Find Quote Report
CMI
Junior Member
**


Posts: 17
Joined: Jul 2004
O.P. RE: StartVideo
Since I'm such a nice guy, I figure I'll help all you people out if you were having StartVideo problems (with this and Messenger 6). No, it still doesn't work, but it doesn't have to. We will be sending a WM_COMMAND message to the IM window, making it think we pressed "Alt+w".

IM windows are made of two parts: The outer window, and a inner object which holds of the entire IM window's contents, not including the menu. You cannot try and send keypresses to the Video button because, guess what, the button doesn't exist! Its simulated.

Even though the the webcam button and menu (note the underscore under w when you hold down Alt) is in the inner object, and not visibly present in the outer window, pressing Alt+W to send a webcam invite is an outer IM window thing. This means getting the handle to that window is enough.

code:
Set imWindow = IMessengerObject.StartVideo(sContact) 'imWindow.HWND is a long containing the hWnd of the new window

After some careful Spy++ing, I can see that the lParam for WM_COMMAND we need to use is 9D57, or 0x9D57, or &H9D57, depending on the language and notation of choice. All we need to do is send this to the IM window using the SendMessage API call. In VB6, it looks like this:

code:
SendMessage imWindow.hwnd, WM_COMMAND, &H9D57, 0

Its so painfully simple, isn't it? Of course, I'm still pretty pissed that IMessenger2.StartVideo doesn't work. Oh well. I should have known.


Edit: In case you didn't notice, this was suggested above, but I initially overlooked the proper value to send to the window, and belive I should be sending things to the inner window.

This post was edited on 07-14-2004 at 02:35 AM by CMI.
07-14-2004 02:33 AM
Profile E-Mail PM Find Quote Report
Destajador
New Member
*


Posts: 1
Joined: Mar 2005
RE: StartVideo
Ok StartVoice or Video are the cmds

And the event fired by this in the Client msn is????

i'm thinking i need first use the MessengerPrivate Library to get this event, is this is On_Accepted fired from Invite:from the remote user, some one test this??

I'dont see the event from the session in the Api library, this is an object containig the Voice_Acepted_Call ???
03-25-2005 11:08 PM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On