Can't drag programs into cmd window, if it's started with admin provilege

8

If I start a CMD window with administrator privilege, I can't drag anything into that window any more.

Usually I'd drag a file into it so that I could get the absolute path of a file, which is impossible now.

Any suggestions? I'm running Windows 7

daisy

Posted 2013-09-22T08:32:38.240

Reputation: 988

Answers

9

This is apparently by design, and for security reasons:

This is how the UAC works. Drag- and Drop are messages. And sending messages from a program with normal rights, to an application with admin rights can cause security issue.

Do Drag & Drop only work with application with the same rights (program with Admin rights to program with admin rights or program with normal rights to program with normal rights ).

Source: http://social.technet.microsoft.com/Forums/windows/en-US/cba0e9b1-25f8-40e5-a888-1435d604f68d/run-as-administrator-prevents-drag-and-drop-working

So you'll have to find some other way to accomplish what you want. One option would be to use the context menu command "Copy as Path" in Windows Explorer (right-click a folder while holding "Shift" to get it).

sleske

Posted 2013-09-22T08:32:38.240

Reputation: 19 887