- Katılım
- 22 Mayıs 2007
- Mesajlar
- 178
- Excel Vers. ve Dili
- 2016 English
Elimede 12 bin satırlı dosya var. A stununda kırmız renkli olanlar gruplansın diye birşey yapabilirmiyiz.
Saygılarımla.
Saygılarımla.
DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
Altın Üyelik Hakkında Bilgi
Elimede 12 bin satırlı dosya var. A stununda kırmız renkli olanlar gruplansın diye birşey yapabilirmiyiz.
Saygılarımla.
Sub Gruplandir()
On Error Resume Next
Cells.Rows.Ungroup
ss = [b65536].End(3).Row
For x = 3 To ss
If Cells(x, 2).IndentLevel > 0 Then Cells(x, 2).InsertIndent -1 * Cells(x, 2).IndentLevel
If Cells(x, 2) Like "??.??.??.??" Then
Cells(x, 7) = 1
ElseIf Cells(x, 2) Like "??.??.??.???" Then
Cells(x, 7) = 2
Else
Cells(x, 7) = 3
End If
If Cells(x, 7) > 0 Then Cells(x, 2).InsertIndent Cells(x, 7)
Next x
Rem ??.??.??.?? şeklinde olanları gruplandır
For x = 3 To ss
If Cells(x, 7) = 1 Then
For y = x To ss
If Cells(y, 7) <> 1 Then
Exit For
End If
Next y
bas = x: son = y - 1:
Range(Cells(bas, 7), Cells(son, 7)).Rows.Group
x = y
End If
Next x
Rem ??.??.??.??? şeklinde olanları gruplandır
For x = 3 To ss
If Cells(x, 7) = 2 Then
For y = x To ss
If Cells(y, 7) <> 2 Then
Exit For
End If
Next y
bas = x: son = y - 1:
Range(Cells(bas, 7), Cells(son, 7)).Rows.Group
x = y
End If
Next x
Columns("G:G").ClearContents
MsgBox "Bittim..."
End Sub
Eline sağlık bir önceki grubu silmemesini sağlayabilirmiyiz.
On Error Resume Next
Cells.Rows.Ungroup
ElseIf Cells(x, 2) Like "??.??.??.???[COLOR="Red"]?[/COLOR]" Then