Page 1 of 1

Windows7, run as admin: Drag&Drop of Pictures does not w

Posted: Fri Feb 07, 2014 10:06 am
by Memnarch
Hi,
Currently, i am facing a problem with Drag&Drop when dragging i.e. pictures from Explorer to my Application.

This works, until i start my application as admin. I know, that this problem is caused by specific messagefilters which prevent communication on windows 7 between admin and non admin processes.

using the winapi functions DragAcceptFiles and ChangeWindowMessageFilterEx, i got it working for other frames, forms and dialogs in my application.

However, i can't get it to work with the TRichViewEdit. It runs fine when not started as admin.

Can someone help me?

Greetings
Memnarch

Posted: Fri Feb 07, 2014 1:07 pm
by Sergey Tkachenko
Windows intentionally blocks drag&drop from a non-elevated to an elevated application, otherwise it would be a security hole (executing code from a non-elevated application inside an elevated application).

TRichViewEdit does not uses messages for drag&drop, it uses OLE interfaces and functions.