我的ListBox属性'RowSource'有问题,我不明白为什么。这是我的方法:
Public Sub lbUsersInProgressRefresh()
'Variable declaration
Dim lastRow As Integer
'Refresh ListBox Users In Progress
lastRow = Worksheets("User In Progress").Range("A" & Rows.Count).End(xlUp).Row + 1
With Worksheets("Main").lbUsersInProgress
.ColumnCount = 5
.ColumnWidths = "50 pt;45 pt;45 pt;45 pt;45 pt"
.ColumnHeads = True
.RowSource = Sheets("User In Progress").Range(Sheets("User In Progress").Cells(1, 1), Sheets("User In Progress").Cells(lastRow, 5)).Address
End With
End Sub
这是我的数据:
这是我的ListBox的结果:
我希望数据以良好的标题来到ListBox。你有想法管理这个吗?