Style in Use vs Formatting in Use

R

RNG

Hello:

I’m querying the styles in use in a document by iterating thru all styles
and using the InUse property. The issue I’m having is that the list of styles
returned is much larger than the styles actually in use in the document.
If I open the document and check Options/Edit/Keep track of formatting, I
can see in the styles task pane the styles that are in use by selecting
“Formatting in useâ€.
How can I query in my code this “Formatting in use†property instead of the
“Styles in use†one?
I appreciate any help.

Thanks in advance!
Ram
 
P

Peter Huang [MSFT]

Hi

From the VBA helper,
InUse Property
This property doesn't necessarily indicate whether the style is currently
applied to any text in the document. For instance, if text that's been
formatted with a style is deleted, the InUse property of the style remains
True. For built-in styles that have never been used in the document, this
property returns False.

So far Word OM modal did not expose such an interface for us to query for
the information about the styles in use.
If you still have any concern, pleas try to post in the office feedback
website.
http://office.microsoft.com/en-us/contactus.aspx

Thanks!

So far you may try to navigate the content one by one and call the
range.Style to enumerate all the styles in use. Or you may try to contact
MSPSS directly to see if there is any other idea.

http://support.microsoft.com

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top