
4,380 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Range(Cells(2, 11), Cells(lastRow, lastCol)).Select ' Starting in row 2 and starting 11 rows over the H will be removed in any columns and rows after that through the end of those columns and rows
Err.Clear
tmpErr = Err.Number
On Error Resume Next
Selection.Replace What:="h", Replacement:="", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
tmpErr = Err.Number
On Error GoTo 0
Did you try this method?
Dim cell As Range
For Each cell In Range(Cells(2, 11), Cells(lastRow, lastCol))
cell.Value = Application.WorksheetFunction.Substitute(cell.Value, "h", "")
Next cell