W
wojjed
Hi
Here's how i fill the list :
Private Sub CommandButton1_Click()
Dim sFilename As Variant
sFilename = Application.GetOpenFilename("Excel files (*.xls; *.csv),
*.xls; *.csv", 0, "Wybierz pliki", 0, True)
For Y = 1 To UBound(sFilename)
ListBox1.AddItem (sFilename(Y))
Next
End Sub
When files are selected i want to open them using Workbooks.Open
(sFilename(Y)) - but in loop that method doesnt work - why ? And how
to obtain text in selected rows ? Supose i have
Private Sub CommandButton2_Click() in which i want to open selected
files - how to do it ?
thx for all sugestions
Here's how i fill the list :
Private Sub CommandButton1_Click()
Dim sFilename As Variant
sFilename = Application.GetOpenFilename("Excel files (*.xls; *.csv),
*.xls; *.csv", 0, "Wybierz pliki", 0, True)
For Y = 1 To UBound(sFilename)
ListBox1.AddItem (sFilename(Y))
Next
End Sub
When files are selected i want to open them using Workbooks.Open
(sFilename(Y)) - but in loop that method doesnt work - why ? And how
to obtain text in selected rows ? Supose i have
Private Sub CommandButton2_Click() in which i want to open selected
files - how to do it ?
thx for all sugestions