SelectedFiles Property

       

Returns an array of WebFile objects representing the selected files.

expression.SelectedFiles

expression   Required. An expression that returns one of the objects in the Applies To list.

Remarks

You must have the Folders view open in the User Interface (UI) in order to select multiple files and you must use the right pane to select the files. From Folders view you can select multiple files in a single web or in multiple webs. If you must use Page view, you can only select one file per web from the left pane.

Tip   You can use the fpWebViewFolders constant of the ViewMode property to set the view to the Folders view.

Example

This example concatenates the names of the selected files.

Note   The delimiter used to separate the file names in the variable mySelName is a space.

Private Sub GetSelectedFileNames()
	Dim myWebWindows As WebWindows
	Dim myWebWindow As WebWindowEx
	Dim mySelFiles As Variant
	Dim mySelFile As WebFile
	Dim mySelName As String
	Dim myCount As Integer

	Set myWebWindows = WebWindows

	mySelFiles = ActiveWebWindow.SelectedFiles

	For myCount = 0 To UBound(mySelFiles)
    		Set mySelFile = mySelFiles(myCount)
    		mySelName = mySelName & " " & mySelFile.Name
	Next
End Sub