Consulting

Results 1 to 2 of 2

Thread: msoFileDialogFilePicker Items Order

  1. #1
    VBAX Newbie
    Joined
    Jan 2016
    Posts
    1
    Location

    msoFileDialogFilePicker Items Order

    I've the following code to select mutiple images to insert to a document, I will like to choose the order using the mouse. I don't know if its possible in the same msoFileDialogFilePicker dialog or bringing the selected images to a new dialog using a different command. From tests with the current command it use the same order as displayed withe the selected items.

    Sub Main()

    Dim fd As FileDialog
    Set fd = Application.FileDialog(msoFileDialogFilePicker)
    Dim vrtSelectedItem As Variant
    With fd
    If .Show = -1 Then

    For Each vrtSelectedItem In .SelectedItems

    MsgBox "The path is: " & vrtSelectedItem

    Next vrtSelectedItem
    Else
    End If
    End With
    Set fd = Nothing
    End Sub

  2. #2
    You will need a userform with two list boxes and a raft of code to sort the order - see http://www.gmayor.com/photo_gallery_template.html
    Graham Mayor - MS MVP (Word) 2002-2019
    Visit my web site for more programming tips and ready made processes
    http://www.gmayor.com

Posting Permissions

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