问题描述
大家好,
我试图找到一种使用API函数SendMessage()或PostMessage()进行拖放的方法,但我使用的是以下代码,但无法正常工作:
Hi All,
I am trying to find a way to preform drag and drop using API function SendMessage() or PostMessage(), I am using the following code but its not working:
API.Click(controlHandleStart, false, (ushort)RelativePointStart.X, (ushort)RelativePointStart.Y);//mouse down
System.Threading.Thread.Sleep(200);
API.Click(controlHandleEnd, true, (ushort)RelativePointEnd.X, (ushort)RelativePointEnd.Y);//mouse up
基本上,我想做的是在Outlook中对电子邮件执行拖放操作,我想将电子邮件拖放到文件夹中,但是我需要使用post/sendmessage.
我只是将鼠标向下拖动到拖动位置,然后再将鼠标向上拖动到放置位置,所以找不到发送鼠标移动消息的方法.
任何人都可以帮忙.
Basically what I am trying to do is to preform a drag and drop for an email in outlook I want to drag an email and drop it into a folder but I need to use post/sendmessage.
I just sending the mouse down on the drag location and then I send the mouse up on the drop location, I am not able to find way to send the mouse move message.
Can anyone help please.
推荐答案
这篇关于使用发布/发送消息拖放的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!