To allow someone to drop something into a control is simple
dragenter put:
if (e->Data->GetDataPresent(DataFormats::Text))
e->Effect = DragDropEffects::Copy;
else
e->Effect = DragDropEffects::None;
and then DragLeave:
whatever the name->Text = e->Data->GetData(DataFormats::Text)->ToString();
But how do you let someone drag something out of your control and put it in
say Word? I've never been able to figure that out.
William DePalo [MVP VC++] - 04 Jul 2006 05:17 GMT
> But how do you let someone drag something out of your control and put it
> in say Word? I've never been able to figure that out.
Then your control needs to become a "drop source". I think it does by
implementing the IDropSource interface:
http://windowssdk.msdn.microsoft.com/en-us/library/ms649605.aspx
But I'm hazy on the details. You might find a more authoritative source of
information in the shell group:
microsoft.public.platformsdk.shell
Regards,
Will