+ Reply to Thread
Results 1 to 2 of 2

how to diable drag & drop / copy functionality for a particular column in excel sheet

Hybrid View

  1. #1
    Registered User
    Join Date
    11-24-2010
    Location
    Toronto
    MS-Off Ver
    Excel 2003
    Posts
    1

    how to diable drag & drop / copy functionality for a particular column in excel sheet

    Hi,

    I saw the option for disabling drag & drop functionality for the entire excel sheet. But, my requriement is to disable the drag - drop /copy functionality to a particular column in an excel sheet.

    Any pointers to this would be of great help.

    Thanks in Advance

  2. #2
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: how to diable drag & drop / copy functionality for a particular column in excel s

    Don't know if this will solve your problem, but it might give you a start

    Put all of this code in the worksheet module for the sheet you want to control.
    Right click the sheet tab and > View Code, paste the code in the resultant pane/window.
    Option Explicit
    
    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
        Dim isect As Range
    
        Set isect = Intersect(Target, Range("F:F"))
    
        If Not isect Is Nothing Then
            Application.CellDragAndDrop = False
        Else
            Application.CellDragAndDrop = True
        End If
    
    End Sub
    This should disable Drag & Drop in Column F, change that range to suit your needs

    Hope this helps
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1