How to Ole Drag/Drop image files to a 3rd party program?

On a VB6 form I have a File1 control listing multiple .JPG files.  In File2 on the same form I have a 3rd party image printing program that will accept OleDragDrop (I've tested it with Explorer, dropping up to five images on it).

I would like to multiselect files from File1 then drag them to the .EXE shown in File2 and drop them, which should have the same effect as working within Explorer, launching the program with the files loaded inside.

It seemed simple until I began and now I need lots of help.

ADDITIONAL CLARIFICATIONS:

The process I need to do is to drag and drop multiple files onto a 3rd party program so that the 3rd party program accepts the files and launches.

This would be similar to having two instances of Explorer open, one pointing to a folder with .JPG files in it and the other instance pointing to a 3rd party .JPG printing program.  Another example would be one Explorer showing .BMP's and the other Explorer showing MS Paint.  Click and drag the .BMP and drop it on the MS Paint program and it will not only launch MS Paint but MS Paint will have the .BMP displayed when it is opened.

I am attempting to do this with a more friendly interface than two instances of Explorer, using the VB Controls File1 and File2.

MORE:
Is it possible to have two instances of Explorer (like a control) within my VB6 project so that the drag and drop onto them and thereby the 3rd party program would be automatic?

Can anybody help?
rrorisonAsked:
Who is Participating?
 
SpideyModCommented:
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange
0
 
Richie_SimonettiIT OperationsCommented:
i have something...let me see...
0
 
rpaiCommented:
Take a look here.
http://pages.cpsc.ucalgary.ca/~saul/vb_examples/tutorial11/imagedrag.html
This might help you code for your requirement.
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
Richie_SimonettiIT OperationsCommented:
try this (it was done with a picture box so you have to do some changes):

VERSION 5.00
Begin VB.Form Form1
   Caption         =   "Form1"
   ClientHeight    =   3600
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   6180
   LinkTopic       =   "Form1"
   ScaleHeight     =   3600
   ScaleWidth      =   6180
   StartUpPosition =   3  'Windows Default
   Begin VB.CommandButton Command1
      Caption         =   "&Select folder"
      Height          =   435
      Left            =   4380
      TabIndex        =   2
      Top             =   3060
      Width           =   1635
   End
   Begin VB.FileListBox File1
      Height          =   2820
      Left            =   60
      Pattern         =   "*.jpg"
      TabIndex        =   1
      Top             =   120
      Width           =   2475
   End
   Begin VB.PictureBox Picture1
      AutoSize        =   -1  'True
      Height          =   2775
      Left            =   2700
      ScaleHeight     =   2715
      ScaleWidth      =   3315
      TabIndex        =   0
      Top             =   120
      Width           =   3375
   End
   Begin VB.Label Label1
      AutoSize        =   -1  'True
      Height          =   195
      Left            =   2160
      TabIndex        =   3
      Top             =   3600
      Width           =   480
   End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Private Sub Command1_Click()

With File1
    .Path = BrowseForFolder(Me.hWnd, "")
    .Pattern = "*.jpg;*.gif"
End With
End Sub


Private Sub File1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
With Label1
    .Caption = File1.Path & "\" & File1.FileName
    .Drag vbBeginDrag
End With
End Sub


Private Sub Picture1_DragDrop(Source As Control, X As Single, Y As Single)
Picture1.Picture = LoadPicture(Label1.Caption)
End Sub
0
 
rrorisonAuthor Commented:

RESPONSES

To rpai:

While the link you provided did indeed have notations regarding drag and drop as a process on a VB project, the referenced link focused primarily on image to image controls.  My original question asked for help regarding multiple image files and ole drag and drop to a 3rd party software program.

To Richie_Simonetti:

As I noted above, my original question did not refer to ole drag and drop from the File1 control to an image control, but for multiple image files being dropped onto a software program, File1 to File2 and have that program launched.


At this time I am requesting to have this question removed so no further Comments or Suggestions should be registered.

My thanks to those who spent time to provide these suggestion.
0
 
Richie_SimonettiIT OperationsCommented:
i didn't use OleDrag!
0
 
DanRollinsCommented:
Hi rrorison,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Refund points and save as a 0-pt PAQ.

rrorison, Please DO NOT accept this comment as an answer.
EXPERTS: Post a comment if you are certain that an expert deserves credit.  Explain why.
==========
DanRollins -- EE database cleanup volunteer
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.