VBA如何结合进度条用户表单代码来做循环

时间:2018-07-10 22:01:44

标签: vba progress

需要帮助为用户表单进度栏正确添加代码。

For Each cel In rList
    Set fnd = ThisWorkbook.Worksheets("Database").Columns("A:A").Find(What:=cel.Value, LookAt:=xlWhole)
    If Not fnd Is Nothing Then
        fndFirst = fnd.Address
        Do
            fnd.Offset(0, 4).Value = cel.Offset(0, 4).Value
            fnd.Offset(0, 5).Value = cel.Offset(0, 5).Value
            fnd.Offset(0, 6).Value = cel.Offset(0, 6).Value
            fnd.Offset(0, 7).Value = cel.Offset(0, 7).Value
            fnd.Offset(0, 8).Value = cel.Offset(0, 8).Value
            fnd.Offset(0, 9).Value = cel.Offset(0, 9).Value
            fnd.Offset(0, 10).Value = cel.Offset(0, 10).Value

            Set fnd = ThisWorkbook.Worksheets("Database").Columns("A:A").FindNext(After:=fnd)
        Loop While fnd.Address <> fndFirst
    End If
Next

我们非常感谢您的帮助。谢谢!

0 个答案:

没有答案