I recently used the Text to Columns feature in Excel to split a column of data into multiple columns based on the space character. Now when I paste text into Excel it automatically splits it into multiple columns without using the Text to Columns feature. Is there a way to revert this functionality back to normal?
3 Answers
This seemed to work, but is a bit involved.
- Enter data into a cell.
- Select the Text to Columns feature.
- Make sure Delimited is selected and choose Next.
- Uncheck the check next to Space (or the delimiter you want to disable)
- Click Finish.
-
Don't forget to mark your answer as the solution @leigh-riffel. It helps the community. Commented May 21, 2012 at 20:05
-
5this worked. so it appears the last text-to-columns operation is used for all future pasting. Commented Jan 18, 2014 at 19:55
-
It's used for all future pasting in any workbook, and also set by default whenever you open a text file.– MohirlCommented Jan 7, 2015 at 11:28
-
argh. obvious (in hindsight) - thanks that's a great timesaver– fostandyCommented Aug 15, 2015 at 9:31
-
2Sad UX!!.. They should have added an "Auto Split" option/checkbox button right next to the Split Text to Columns button. Commented Nov 30, 2016 at 18:29
I created a quick Macro and added it to my personal.xlsm file. Here is the code. This more or less does the same thing that Leigh Riffel has suggested except it is a quick Macro run.
Sub DisableAutoSplitting()
Selection.TextToColumns Destination:=Range("C2"), DataType:=xlDelimited, _
TextQualifier:=xlDoubleQuote, ConsecutiveDelimiter:=False, Tab:=False, _
Semicolon:=False, Comma:=False, Space:=False, Other:=False, FieldInfo _
:=Array(1, 1), TrailingMinusNumbers:=True
End Sub
-
1
-
This only works is there's already data in the range of the selection. To make this work, i added a bit that sets a value (a string with a single space char), and wrapped a copy/paste to/from memory around it. See my next comment.– ikku100Commented Apr 3 at 9:54
-
` Sub DisableAutoSplitting() Dim v As Variant ActiveSheet.Range("a1").Select v = Selection.Value Selection.Value = " " Selection.TextToColumns Destination:=Selection, DataType:=xlDelimited, _ TextQualifier:=xlDoubleQuote, ConsecutiveDelimiter:=False, Tab:=False, _ Semicolon:=False, Comma:=False, Space:=False, Other:=False, FieldInfo _ :=Array(1, 1), TrailingMinusNumbers:=True ActiveSheet.Range("a1").Select Selection.Value = v End Sub `– ikku100Commented Apr 3 at 9:54
Or just click into the formula bar or into the cell as if you are typing, then paste - it will then only go into that cell. (LOL creating a macro - so over complicated)
-
2This works if you're trying to paste into only one cell. It doesn't work for pasting into multiple rows because all the lines end up in the one cell.– kruboCommented Nov 11, 2016 at 23:33