Archive for May 28th, 2009

Excel : Search And Replace by VBscript.

Sub Replace()

Application.ScreenUpdating = False
Application.Calculation = xlManual
Dim cell As Range
For Each cell In Intersect(Selection, _
ActiveSheet.UsedRange)
If IsNumeric(cell) = False And Trim(cell) = “.” And cell.Row > 1 Then
cell.Value = “”
End If
Next cell
Application.Calculation = xlAutomatic ‘xlCalculationAutomatic
Application.ScreenUpdating = False

End Sub
Adding the Macro
1. Copy the macro above pressing the keys CTRL+C
2. Open your workbook
3. Press the keys ALT+F11 to open [...]

Continue reading »