effeff schrieb am 22.July.2009, 11:12:45 in der Kategorie pc.coding
Option Explicit
Sub SehrLangsamesErsetzen()
Dim Wb As Workbook
Dim Ws As Worksheet
Dim Rg As Range
Dim Cl As Range
Dim Zellinhalt As String
Dim Suchinhalt As String
Dim Ersatzinhalt As String
Set Wb = ThisWorkbook
Set Ws = Wb.Sheets(\"Tabelle1\")
Set Rg = Ws.Range(\"A1:A10\")
Suchinhalt = \"Zug\"
Ersatzinhalt = \"Dampfschiff\"
For Each Cl In Rg.Cells
Zellinhalt = Cl.Value
If Zellinhalt = Suchinhalt Then
Cl.Value = Ersatzinhalt
End If
Next
End Sub