Do you know how to transpose the numbers within a cell, for example, cell A1 says 12345, I want cell B1 to say 54321. Is that possible?
Dave sent me to a web site to get this formula.
How does it work?
Function ReverseCell(Rcell As Range, Optional IsText As Boolean)
Dim i As Integer
Dim StrNewNum As String
Dim strOld As String
strOld = Trim(Rcell)
For i = 1 To Len(strOld)
StrNewNum = Mid(strOld, i, 1) & StrNewNum
If IsText = False Then
ReverseCell = CLng(StrNewNum)
ReverseCell = StrNewNum
Using the loop (i = 1 to Len(stgOld)) starts it off. When the Mid function is used inside the loop causes each character to be used. What would happen if the Len was used? Only one character would be shown?
Did it work for your data?
Len is used to return the number of characters in a String. This is what is used to determine how many loops to perform.