|
超初心者 さんありがとうございました。
無事にうまくいきました。
▼超初心者 さん:
>▼とってぃ さん:
>
>> Private Sub CommandButton1_Click()
>> Dim i As Integer
>> Dim myName As String
>> Dim pasu As String
> Dim myBook As Workbook
>>
> Set myBook = ActiveWorkbook
>> With ListBox1
>> For i = 0 To ListBox1.ListCount - 1
>> If ListBox1.Selected(i) Then
> myBook.Activate
>>> ' Worksheets(.List(.ListIndex)).Select
> Worksheets(.List(i)).Select
>> pasu = ActiveWorkbook.Path
>> ActiveSheet.Copy
>> myName = ActiveSheet.Name
>> End If
>> Next i
>> End With
>> End Sub
>
>こんな感じでいかがでしょう。
|
|