PDA

View Full Version : Find Copy and Paste



ozuberk
04-19-2018, 12:19 AM
Is it possible to get the numbers 13 characters long starting from 260 in the contents of cells A1: D10000? For example: On cell A1: 2601234567890 On cell A10: Excel ***xx 2601234567890 D15 Cell: Trial ***x 2601234567890 Excel ***xx


Thank you, easy.

Paul_Hossler
04-19-2018, 11:06 AM
Something like this possibly?




Option Explicit

Sub MaybeThis()
Dim r As Range

For Each r In ActiveSheet.Range("A1:D10000").SpecialCells(xlCellTypeConstants).Cells
r.Value = CStr(Right(r.Value, 13))
Next
End Sub

ozuberk
04-25-2018, 04:07 AM
Thanks Paul_Hossler, Will try out and get back to you.

Regards
Ozuberk