Click here to Skip to main content
15,892,298 members
Home / Discussions / C#
   

C#

 
AnswerRe: Custom Event and Cross-thread operation not valid Question Pin
N a v a n e e t h13-Aug-09 1:25
N a v a n e e t h13-Aug-09 1:25 
QuestionRe: Custom Event and Cross-thread operation not valid Question Pin
Programm3r13-Aug-09 1:35
Programm3r13-Aug-09 1:35 
Questioninvoking events of a control under another control Pin
jamesjk12-Aug-09 20:27
jamesjk12-Aug-09 20:27 
AnswerRe: invoking events of a control under another control Pin
Eslam Afifi12-Aug-09 21:34
Eslam Afifi12-Aug-09 21:34 
GeneralRe: invoking events of a control under another control Pin
jamesjk13-Aug-09 0:02
jamesjk13-Aug-09 0:02 
GeneralRe: invoking events of a control under another control Pin
Eslam Afifi13-Aug-09 18:05
Eslam Afifi13-Aug-09 18:05 
GeneralRe: invoking events of a control under another control Pin
jamesjk13-Aug-09 22:05
jamesjk13-Aug-09 22:05 
GeneralRe: invoking events of a control under another control Pin
Eslam Afifi14-Aug-09 2:58
Eslam Afifi14-Aug-09 2:58 
jamesjk wrote:
but nothing special happened...
no event in the message receiving control was fired..
am I missing anything ?

The code was not to fire the events. It was to help you find the right message sequence and the lParam and wParam values to pass (read msdn documentation of those messages to find out the correct values to pass). You send the messages using SendMessage.

So I guess the sequence would be sending,
WM_LBUTTONDOWN in mousedown event
WM_MOUSEMOVE in mousemove
WM_MOUSEHOVER in mousehover (just in case the covered control uses it for something, i don't know. the same applies to WM_MOUSELEAVE)
WM_LBUTTONUP in mouseup

I don't know anything about WM_COMMAND nor 0xc206 (I couldn't find anything about it, maybe it's an undocumented message, i don't know). I think you shouldn't use WM_SETFOCUS and WM_KILLFOCUS. WM_CAPTURECHANGED, i don't know, maybe you should send it right after WM_MOUSEUP in mouseup event.

P.S. I've never tried to simulate something like dragging before but I did try sending simple messages before. I don't know much so you should experiment more. And study sequences generated from cases like mousedown, move, leave the control, re-enter the control, move, mouse up... (cases like that) to ensure you get the desired result in both normal cases and extreme cases. And you're welcome.

Eslam Afifi

AnswerRe: invoking events of a control under another control Pin
kb-boxer13-Aug-09 1:00
kb-boxer13-Aug-09 1:00 
Generalinvoking events of a control under another control Pin
jamesjk13-Aug-09 1:15
jamesjk13-Aug-09 1:15 
Questioninvoking events of a control under another control -- i shall make it clearer Pin
jamesjk13-Aug-09 1:16
jamesjk13-Aug-09 1:16 
QuestionAdding Dll reference problem........ Pin
shaina223112-Aug-09 20:06
shaina223112-Aug-09 20:06 
AnswerRe: Adding Dll reference problem........ Pin
Eslam Afifi12-Aug-09 21:01
Eslam Afifi12-Aug-09 21:01 
QuestionHow to identify the Process, that is created using Code ? Pin
Jacobb Michael12-Aug-09 19:03
Jacobb Michael12-Aug-09 19:03 
AnswerRe: How to identify the Process, that is created using Code ? Pin
V.12-Aug-09 20:27
professionalV.12-Aug-09 20:27 
GeneralRe: How to identify the Process, that is created using Code ? Pin
Jacobb Michael13-Aug-09 5:23
Jacobb Michael13-Aug-09 5:23 
QuestionC# Save the the last entered data on application exit and reload it on application start. Pin
maheesh12-Aug-09 16:49
maheesh12-Aug-09 16:49 
AnswerRe: C# Save the the last entered data on application exit and reload it on application start. Pin
N a v a n e e t h12-Aug-09 16:51
N a v a n e e t h12-Aug-09 16:51 
GeneralRe: C# Save the the last entered data on application exit and reload it on application start. Pin
maheesh12-Aug-09 18:50
maheesh12-Aug-09 18:50 
GeneralRe: C# Save the the last entered data on application exit and reload it on application start. Pin
Christian Graus12-Aug-09 19:00
protectorChristian Graus12-Aug-09 19:00 
GeneralRe: C# Save the the last entered data on application exit and reload it on application start. Pin
maheesh12-Aug-09 19:19
maheesh12-Aug-09 19:19 
AnswerRe: C# Save the the last entered data on application exit and reload it on application start. Pin
Mycroft Holmes12-Aug-09 18:08
professionalMycroft Holmes12-Aug-09 18:08 
AnswerRe: C# Save the the last entered data on application exit and reload it on application start. Pin
mustang8612-Aug-09 20:00
mustang8612-Aug-09 20:00 
AnswerRe: C# Save the the last entered data on application exit and reload it on application start. Pin
wjp_auhtm12-Aug-09 21:07
wjp_auhtm12-Aug-09 21:07 
GeneralRe: C# Save the the last entered data on application exit and reload it on application start. Pin
maheesh12-Aug-09 22:16
maheesh12-Aug-09 22:16 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.