Restart Each Section means that line numbering will start over in each section. You must use headers for Microsoft Word to be able to do this. Restart on each page means that each page's first line will be numbered ‘1." Microsoft Word will label the first line "1," the second line "2," and so on throughout the entire document. If you click the Line Numbers button, you will see this dropdown menu:Īs you can see, None is selected by default. You can also select:Ĭontinuous to display every line number within the document. To display line numbers, go to the Layout tab. Click on Line Numbers in the Page Setup group, as shown below. This is especially helpful in technical papers to create reference points. You can display line numbers in all or part of a document, or at certain intervals such as every tenth line. You have to specify if you want Word to show line numbers and which ones to display. However, it does not show these line numbers. By default, Microsoft Word numbers every line in a document except for those in tables, footnotes, endnotes, text boxes, frames, as well as headers and footers. It would take a while to try all of them. This tip examines five ways you can copyġ5K recipes, that is a lot (to put it mildly). Once perfected, however, you may want to copy those styles from one document to another.
If you use styles in your documents, you know it can take a good investment of time to get them just the way you want. What you could do is copy it from that document to others I have been fighting with this reformatting for years before deciding to research deeper and start asking more questions. Thanks a whole bunch for helping me out with this issue. This Macro is really great, it worked like a champ. Set diaFolder = Application.FileDialog(msoFileDialogFolderPicker)Įnd Function Andrew Lockton Melbourne Australia Set aDoc = Documents.Open(FileName:=sFolder & "\" & JName)ĪDoc.Paragraphs(1).Range.Style = "Heading 2"įunction SelectFolder(Optional sTitle As String = "Select a Folder") As String Note there is a separate function for the selection of a folder.ĭim JName As String, aDoc As Document, sFolder As String It is frowned upon to do lots of local formatting and use selection objects.
' all existing code in the While loop here Set fDialog = Application.FileDialog(msoFileDialogFolderPicker) docm if you have those), add an asterisk at the end to make it *.doc* (again, see below). The result of that picker, the path to the folder that contains the files, should be included in the first assignment of JName (see code below).Īlso, if some of the documents don't have the ".doc" extension, your macro will skip those files. Instead of using the FileOpen dialog, you could use a "folder picker" such as the one explained at. That way we can see exactly what is happeningĬan you tell whether the macro is doing anything to the documents in the selected folder? If not, then perhaps the macro isn't looking in the right place for the documents and isn't working on any of them. Then include some body text that you can tell us should have the various heading levels applied. Start with lines showing just your heading styles as you want them to look.
If you have applied "styles" manually, rather than using the style feature, then you can use find and replace to find the manual formatting and replace it with the required style.Ĭould you upload a small sample of your file, 3-4 pages should be more than enough as long as it has examples of all of the styles you need to use. If you have used styles, but then manually applied formatting, ie italics, then you can use find and replace to remove the manual formatting. You change the style definition, and automagically, all uses of the style in the document are updated to reflect the changes to the style.
The thing is, If you use Word styles correctly, then changing formatting is simple. Then apply the appropriate styles where needed. Why don't you just modify the heading styles as required. I don't follow what you are trying to do with the document and the macro. In the Format for Paragraph, Spacing is set for Size " 14", " Bold" is Highlighted, "Italic & Underscore " is Not Highlighted How do I change this so the formatting in the Modify Style, Selection.Style = ActiveDocument.Styles("Heading 2")ĪctiveDocument.Close SaveChanges:=wdSaveChanges Selection.EndKey Unit:=wdLine, Extend:=wdExtend Thus, things like paper size, margins, header and footer locations, and orientationĪ FileName:=JName Here is the macro I had found on the web and currently using:
Hope you all can help out this old man, retired for many years. Word mainly just changes the Heading format to be an Italic. but Word 2010 will change the formatting to something else from the macro that it running. I have a lot of recipes and now going back over them and changing all formatting to just one format.