Results 1 to 3 of 3

Thread: Drag And drop

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jul 2000
    Location
    Lost in the Mojave Desert
    Posts
    82
    Hey anyone know where i can find the details on when you click on a file form explorer and drag and drop it on a control,what info is gathered and where it is stored.
    what im looking to do is drag and drop specific file types onto a listbox and have the listbox display the path where the file resides including the filename. thx in advance
    Don't go away mad, just go away.

    Bam-Bam

  2. #2
    Guest
    Put a listbox on the form and set it's OLEDropMode property to Manual.

    Code:
    Private Sub List1_OLEDragDrop(Data As DataObject, _
    Effect As Long, Button As Integer, Shift As Integer, X As _
    Single, Y As Single)
    
    If Data.GetFormat(vbCFFiles) Then List1.AddItem Data.Files(1)
    
    End Sub
    Drag files on to the Listbox and watch what happens .

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Jul 2000
    Location
    Lost in the Mojave Desert
    Posts
    82
    thanks it worked very well i even changed the code for multiple file drag/drop and extension verification,just when you think you have a pretty good handle on vb something pops up and the only thing you can do is scratch your head, must go read up on ole again thanks again
    Don't go away mad, just go away.

    Bam-Bam

Posting Permissions

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



Click Here to Expand Forum to Full Width