0
This seems like it should be simple enough to do, but I'm having a hard time doing it. I have a bunch of documents that we use for development in plain text so that I can automate the creation of these documents via scripts. Management wants all finalized documents in Word format. If i have a plain text numbered list like this:
1. Heading
1.1 sub
1.2 sub
2. Heading
2.1 sub
How can I get that into any version of Word so that Word recognizes it as a numbered list and not just plain text that happens to start with numbers?
1Can your numbers be recreated entirely from the structure? E.g., is the 3rd level 2 para below the 4th level 1 para always going to be para 4.2? If so, then you could consider using a standard sequence of replace operations in Word to find, e.g. [0-9].[0-9] using wildcards (the pattern needs a little work) and replace with Style Heading 2. Then repeat for [0-9]. And Heading1. Then apply the appropriate outline numbering scheme (or predefined it in your Word template). – None – 2014-01-10T07:01:42.933
@bibadia They could be redacted. What you are suggesting is actually similar to what we are doing now. I was looking for a way to just run a script and then have final documents with no manual steps or Word automation. – user21826 – 2014-01-20T17:55:28.590
Not sure what you mean by "redacted" in this situation. Does it makes things simpler or more complicated? If you have a document with a multilevel numbering structure set up for Heading1, etc., with predictable numbering, all you have to do is surround each paragraph with the appropriate html heading level tags ( <h1>, <h2> etc., remove the manual numbering, replace special characters such as "<" as needed, put it all inside an <html> element, and insert that into the Word document (cf. Tonny's Answer). Mostly feasible outside Word. I'd have to think about the last bit. – None – 2014-01-21T15:02:42.083