Hi everyone,
I created a Macro to convert numbers formatted as text to number formats. The code has worked correctly for me, but today I selected an entire column by clicking the column header and tried this, to which it populated an error: Run-Time error "424". I can't seem to get it to work anymore, even after removing the code and retyping.. I'm wondering if excel is stuck in some sort of loop now that I need to exit? I've tried pausing and doing resets through VBA, but that hasn't solved the issue. Please let me know if there is anything I can do or if I possibly have some incorrect coding here.
Here is the coding:
Sub TextToNumber()
'
' TextToNumber Macro
' Converts Text to Number Format
'
' Keyboard Shortcut: Ctrl+l
'
Cells.SpecialCells(xlCellTypeLastCell) _
.Offset(1, 1).Copy
Seleciton.PasteSpecial Paste:=xlPasteValues, _
Operation:=xlPasteSpecialOperationAdd
With Selection
.VerticalAlignment = xlTop
.WrapText = False
End With
Selection.EntireColumn.AutoFit
End Sub
I created a Macro to convert numbers formatted as text to number formats. The code has worked correctly for me, but today I selected an entire column by clicking the column header and tried this, to which it populated an error: Run-Time error "424". I can't seem to get it to work anymore, even after removing the code and retyping.. I'm wondering if excel is stuck in some sort of loop now that I need to exit? I've tried pausing and doing resets through VBA, but that hasn't solved the issue. Please let me know if there is anything I can do or if I possibly have some incorrect coding here.
Here is the coding:
Sub TextToNumber()
'
' TextToNumber Macro
' Converts Text to Number Format
'
' Keyboard Shortcut: Ctrl+l
'
Cells.SpecialCells(xlCellTypeLastCell) _
.Offset(1, 1).Copy
Seleciton.PasteSpecial Paste:=xlPasteValues, _
Operation:=xlPasteSpecialOperationAdd
With Selection
.VerticalAlignment = xlTop
.WrapText = False
End With
Selection.EntireColumn.AutoFit
End Sub