Join
Sign in
Search Options
Search Everything
Search Formats
Home
Blog
Resources
Forums
About Open XML
More ...
Home
»
Forums
»
Formats
»
WordprocessingML
»
Renaming Styles
Re: Renaming Styles
Formats
Discussions about working with different Open XML Formats
Get this RSS feed
Details
2
Replies
0
Subscribers
Posted
over 3 years ago
Options
Subscribe via RSS
Share this
WordprocessingML
Renaming Styles
rated by 0 users
This post has
2 Replies |
0
Followers
nomad311
50
Posted by
nomad311
on
Thu, Oct 1 2009 3:37 PM
rated by 0 users
Post Points: 20
Renaming Styles
In my attempt to go through and rename styles before feeding multiple docx's into a merge library I have created a large and complicated routine that modifies the <w:style w:styleId="..."> and <w:name w:val="..."> attributes of the style element. Then modifies any reference to old style id's in the rest of the docx.
This seems as if it shouldn't be this laborious, does anyone know of a better way?
-nomad311
Xiaoyuvax
635
Posted by
Xiaoyuvax
on
Thu, Oct 1 2009 11:56 PM
rated by 0 users
Post Points: 20
Re: Renaming Styles
i am working on styles too these days, i don't know what is the laborous work you've done in your code, but i would like to hint whether you've noticed that the SDK has provided certain properties in the Style class ,through which your code could directly access the Style children which are mostly of single key-value pairs,read the code hereunder:
Style s = new Style();
s.StyleID = "New Style";
s.StyleName = "New Style Name";
...
Welcome to visit my Blog:xiaoyuvax.spaces.live.com Follow me on Twitter: twitter.com/xiaoyuvax
nomad311
50
Posted by
nomad311
on
Fri, Oct 2 2009 9:04 AM
rated by 0 users
Post Points: 5
Re: Renaming Styles
I can only assume that your using the 2.0 SDK, which I am unfortunately unable to use in its current state :(
Thanks for the suggestion though,
-nomad311
Page 1 of 1 (3 items)