Disable Drag And Drop

This handy piece of JavaScript will disable the drag and drop function for all library web parts on a single page. Other upload options will still work.

Just paste this into a Script Editor web part:


<script>

ExecuteOrDelayUntilScriptLoaded(function() {

    g_uploadType = DragDropMode.NOTSUPPORTED;

    SPDragDropManager.DragDropMode = DragDropMode.NOTSUPPORTED;

}, "DragDrop.js");

</script>

Advertisement

One thought on “Disable Drag And Drop

  1. I was recommended this website via my cousin. I’m now not positive
    whether this submit is written by way of him as no one else recognise such specific approximately my difficulty.
    You’re amazing! Thank you!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s