Sub 提取延期绩效()
bmr = Array("机械", "天津", "深圳", "安徽")
For x = 0 To UBound(bmr)
For col = 8 To 13
Call jx(bmr(x), col, col + 2008)
Next col
Next x
End Sub
Sub jx(bm, col, nf)
i = 1
j = 1
Do
If ActiveSheet.Cells(i, j) Like bm & "" Then
Exit Do
End If
i = i + 1
Loop
Class5_Row_Start = i
Do
If Not (ActiveSheet.Cells(i, j) Like bm & "") Then
Exit Do
End If
i = i + 1
Loop
Class5_Row_End = i - 1
Dim Mech_Row5 As Integer
Set subtc = Sheets(Left(bm, 2) & "当期绩效").Columns(3).Find(nf & "年小计")
If Not subtc Is Nothing Then
Mech_Row5 = subtc.Row
For i = Class5_Row_Start To Class5_Row_End
Set find_namec = Sheets(Left(bm, 2) & "当期绩效").Rows("4:5").Find(Sheets("前台部门").Cells(i, 2))
If Not find_namec Is Nothing Then
j = find_namec.Column
Sheets("前台部门").Cells(i, col) = Sheets(Left(bm, 2) & "当期绩效").Cells(Mech_Row5, j)
End If
Next i
End If
End Sub