- Sub qcw()
- Application.ScreenUpdating = False
- Dim x%, i%, cl%
- For x = 1 To 4
- n = Cells(7, x)
- If n Like "*~*" Then
- n = Left(Cells(7, x), 3) & "~" & Right(Cells(7, x), 2)
- End If
- Set Rng = Range(Cells(11, 6), Cells(11, Columns.Count)).Find(n, lookat:=xlWhole)
- If Not Rng Is Nothing Then
- cl = Rng.Column
- End If
- For i = 12 To Range("b65536").End(xlUp).Row
- If Cells(i, cl) <> "x" Then Rows(i).EntireRow.Hidden = True
- Next i
- Next x
- Application.ScreenUpdating = True
- End Sub
复制代码 |