|
sheetの指定が抜けていました。
Private Sub ComboBox1_Change()
With Sheets("Sheet1")
Select Case Me.ComboBox1.ListIndex
Case 0
Me.ComboBox2.List = .Range("A1", .Range("A65536").End(xlUp)).Value
Case 1
Me.ComboBox2.List = .Range("B1", .Range("B65536").End(xlUp)).Value
Case 2
Me.ComboBox2.List = .Range("C1", .Range("C65536").End(xlUp)).Value
Case 3
Me.ComboBox2.List = .Range("D1", .Range("D65536").End(xlUp)).Value
Case 1
Me.ComboBox2.List = .Range("E1", .Range("E65536").End(xlUp)).Value
End Select
End With
End Sub
|
|