|
[广告] VBA代码宝 - VBA编程加强工具 · VBA代码随查随用 · 内置多项VBA编程加强工具 ★ 免费下载 ★ ★ 使用手册★
Private Sub CommandButton1_Click()
Dim h As Long
For h = 3 To Range("a10000").End(xlUp).Row
If Cells(h, "s") <> "" And Cells(h, "s").NoteText = "" Then
Range(Cells(h, 1), Cells(h, 25)).Copy Sheet2.Cells(Sheet2.Range("a10000").End(xlUp).Row + 1, 1)
Sheet2.Cells(Sheet2.Range("a10000").End(xlUp).Row, "s").NoteText "已转录到离职员工"
End If
If Cells(h, "v") <= 18 And Cells(h, "v").NoteText = "" Then
Range(Cells(h, 1), Cells(h, 25)).Copy Sheet3.Cells(Sheet3.Range("a10000").End(xlUp).Row + 1, 1)
Sheet3.Cells(Sheet3.Range("a10000").End(xlUp).Row, "v").NoteText "已转录到未成年员工"
End If
Next h
End Sub
考虑资料的保存,对原表未做删除处理,但做了记号,不会二次转录。
|
|