sir
Can we activate a window message artificialy e.g mouse click
Niaz
Printable View
sir
Can we activate a window message artificialy e.g mouse click
Niaz
Hi,
What do you want exactly?
Do you want to have a message come up after you clicked e.g. a form window in VB?
A simple reply would be
Private Sub Form_Click()
MsgBox "Text........"
End Sub
Otherwise provide more details.
Jan
Yes. You can synthesise a mouse or keyboard event with mouse_event and keybd_event. But this works on WinNt only. and also MSDN says oflate you should use SendInput APi. NT-specific.
In vb, if you just want to do what you do on a event, mouse click - for example, you can call that function directly in code.
Private sub Form_Click()
... some things happens here
end sub
You want the same thing to happen even if a btn is clicked, say, then
Private sub Command1_Click()
call Form_Click()
end sub
Check if this kind of thing is sufficient for your case.
RK