AW: Zuordnung auf Tabellenblätter
27.01.2010 15:36:18
fcs
Hallo Gero,
hier am Beispiel von LISA, wie du die beiden Button-Makros anpassen muss.
Gruß
Franz
Private Sub CommandButton1_Click()
Dim Zeile
With Sheets("LISA")
Zeile = .Cells(.Rows.Count, 2).End(xlUp).Row + 1
Selection.Copy .Cells(Zeile, 2) 'Kopieren nach Spalte B
Selection.Offset(0, 5).Copy .Cells(Zeile, 3) 'Kopieren nach Spalte C
Selection.Offset(0, -1).Copy .Cells(Zeile, 1) 'Kopieren nach Spalte A
End With
Selection.Offset(0, -1).Interior.ColorIndex = 5
Range(Selection.Offset(0, 1), Selection.Offset(0, 6)).Interior.ColorIndex = 5
End Sub
Private Sub CommandButton7_Click()
Dim Zeile
Sheets("LISA").Range("A:C").Clear
With Sheets("CLIPBOARD TOTAL")
For Zeile = 12 To .Cells(.Rows.Count, 2).End(xlUp).Row
'Farbe in SPalte A prüfen
If .Cells(Zeile, 1).Interior.ColorIndex = 5 Then
'Farbfüllung = keine Füllfarbe
.Cells(Zeile, 1).Interior.ColorIndex = xlColorIndexNone
.Range(.Cells(Zeile, 3), .Cells(Zeile, 8)).Interior.ColorIndex = xlColorIndexNone
End If
Next
End With
End Sub