I have a simple text file with columns of numbers.
For example:
Number … X …|… Y …|… Z
1 … 123456.78 | 987654.12 | 123.45
2 … 774588.77 | 855465.12 | 222.55
3 … 111111.11 | 222222.22 | 122.23
4… 222211.11 | 251111.33 | 455.12
5… 242121.11 | 222445.22 | 667.88
and so on, for a thousand rows.
I need to cut one of the columns (one at at time) and leave the rest in place.
I want to cut and paste each column of numbers , and insert them into two other documents, in different locations.
One document is an Excell spreadsheet, the other is a simple ASCII text file.
I need to manipulate each column separately.For example, switch the X and Y columns
to look like:
1 987654.12 123456.78 123.45
2 855465.12 774588.12 222.55
How do I do it with Windows Notepad, and Open Office?
This should be trivial, and I apologize for being stupid. (I can do it with an ancient DOS text editor–so if it was 1993, I’d be okay. Help me join the 21st century!)
No, it is not trivial. Whether it is doable depends on how the program is written, most text editors do not provide for vertical selections. With the example you showed, you could replace the blanks by tab characters, then open the file with EXCEL and the tabs would place the different numbers in separate columns (or do a blank delimited import in EXCEL).
Alternatively, I think the crimson editor supports vertical selections.
Circa 1992, in the old DOS days, I got a shareware DOS editor called QEDIT that could do lots of tricks like this. I still use that editor for most of my editing to this day. Various moderns editors can deal with it. I see someone has already suggested Notepad++ which is what I was going to suggest.
Screw Notepad. That’s barely more that a (slightly) updated EDLIN with a GUI front end grafted on.
ETA: Notepad++ is freeware, I believe. So that’s a good choice.
Why deprive yourself of Qedit? It still works fine, as a DOS CLI-style program in a Command Prompt window. I still use it to this very day as my primary editor for writing/maintaining plain-old-plain-text files, program source files in particular.
Regrettably, there are fewer and fewer people still alive who even know what a “plain old plain text file” is. Every time I ask around for a new printer that can still print plain text files, all I get from the people at computer stores is a blank brain-dead stare.
I see that Digital is the new Analog has already mentioned TextPad. This is a good, very sophisticated, GUI-based editor. Another very sophisticated GUI-based editor is UltraEdit, incorporating just about every feature every editor is ever known to have had; it is [del]practically[/del] a full-fledged development environment. It even has a mode for editing arbitrary binary files. (I think TextPad does too.) As for the OP’s original question, they both have block mode too (that is, the ability to select and act upon rectangular subsets of the text). These are not freeware, but quite probably well-worth-the-price-ware.
The above links point to their respective Wikipedia pages.
Oh, by the way: The reason Qedit had so many of “the right short-cuts” is because it was based on the well-established de-facto WordStar command set. The standard DOS Editor that was shipped with DOS systems was not as comprehensive, but was also based on the WordStar command set.
ETA: Musicat: Do you still wish to use Qedit, but no longer have it? PM me. I could e-mail you a copy of the Q.EXE file. Don’t know if it’s the latest version they published, but it’s worked fine for me. Or, just look into it’s new incarnation as TSE.
More ETA: Assuming we’re talking about the same Qedit. Apparently there were numerous editors with that, or similar, name.
Yep, it was the first thing I thought of. I’m not sure why all these other suggestions are coming up - especially since the OP says he has Excel and plans to use it in the end anyway.