SEARCH

The How-To Geek Forums Have Migrated to Discourse

How-To Geek Forums / Microsoft Office

(Solved) - MS Word: Add line numbers to end of each line

(3 posts)
  • Started 1 year ago by deboo
  • Latest reply from deboo
  • Topic Viewed 941 times

deboo
Posts: 2

I have a word 2007 file having text in an Indian language (Hindi) containing line numbers on each line. About 12 pages. Some lines are bolded, some are italicized and others are colored.

What I want is to sort text in Hindi first but retain the line numbers. This is not possible I guess since the numbers will remain at their place. Sorting of text is fine, though.

The next best thing I can do is copy the text along with line numbers into wordpad and back to word, then sort the text. But this way, the sorting is done based on numbers and not text.

Another thing I can do is to remove the line numbers from the start of each line and add the line numbers to end of each line, say in brackets. But doing this manually is extremely tedious. And if I completely remove the numbering, is there a way I can add numbering to the end of each line?

I am aware that this can be done easily in Linux/UNIX using the sed tool but even if I had Linux installed, and used sed to do this, I'd had to loose the formatting of my text.

Is there anyway that I can do what I want in Word itself, without having to do it manually for each line?

Posted 1 year ago
Top
 
moreeg
moreeg
Posts: 842

Hi deboo

Another option is to paste/special/HTML into column B of a new Excel spreadsheet. This will keep the formatting. In Column A you can put in the row numbers - enter 1 in the first row and drag down to the last and use Paste/Fill in the small icon that will appear. You can then sort by Column A or Column be as you need and then copy and paste it back into a Word document.

Accepted Answer · Posted 1 year ago
Top
 
deboo
Posts: 2

Thanks moreeg, that worked very well. Lots of time saved!

Kind Regards,
Deboo

Posted 1 year ago
Top
 



Topic Closed

This topic has been closed to new replies.

Enter Your Email Here to Get Access for Free:

Go check your email!