Greetings. Using the Words component I am trying to apply a style to all lists within a document, however I can’t seem to figure out how to successfully do this. I believe I am missing overlooking something that is easy. The following code describes what I am attempting. Can someone please let me know what I should write in the “***what code should go here” portion of the foreach loop to apply the defined style to each list in the document? Many thanks.
List listStyle = doc.Styles.Add(StyleType.List, "MyListStyle");
// style properties omitted
Lists myInsertedlists = doc.Lists;
foreach (List singleList in myInsertedlists) {
*** what code should go here?
}