Hi auch,
oder so ähnlich, x für zusammenhängende Spalten, y für gesamten Zeilentausch:
Sub x()
Dim a, b, i As Byte
For i = 3 To 10 'Spalte C bis J
a = Cells(2, i).Value: b = Cells(4, i).Value
Cells(2, i) = b: Cells(4, i) = a
Next
End Sub
Sub y()
Dim a, b
a = Range(Cells(2, 1), Cells(2, 256)): b = Range(Cells(4, 1), Cells(4, 256))
Range(Cells(2, 1), Cells(2, 256)) = b: Range(Cells(4, 1), Cells(4, 256)) = a
End Sub
lg Nancy
Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP