Text Runs in VBA?

A

Abhishek

Hi!

Can someone please tell me how can I get the text runs of the word doc
through VBA code or whether or not they are possible at all.
I think they should be accessible since they appear in the XML genrated from
word

Thanks
Abhishek
 
D

Doug Robbins - Word MVP

Maybe ActiveDocument.Range.Text

But I am not really sure what you mean by "text runs"

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP
 
A

Abhishek

A textrun specifies the collection of continous text with same formatting
In a paragraph whenever there is a change in formatting that constitutes the
a RUN
Total number of runs in a paragraph is equal to the total no of changes in
formatting within the paragraph

In WordML it is denoted by <w : r>
 
K

Klaus Linke

Abhishek said:
A textrun specifies the collection of continous text with same formatting
In a paragraph whenever there is a change in formatting that constitutes
the a RUN
Total number of runs in a paragraph is equal to the total no of changes in
formatting within the paragraph

In WordML it is denoted by <w : r>


Hi Abhishek,

No, unfortunately not. I've asked for a VBA method that returns the range of
the text run, given some position in the doc. And maybe if you and enough
others ask for something like that too, it might get implemented some day
(... shouldn't be too hard to implement, I'd think, and would be very useful
to speed up macros in lots of situations, since it would avoid the necessity
to look at individual characters).

If you can, you might just work with the WordML?

Regards,
Klaus
 
K

Klaus Linke

a VBA method that returns the range of the text run, given some position
in the doc

.... or, if that's easier to implement, a method that returns the end of the
text run, or a range from the chosen position to the end of the run?

Klaus
 
A

Abhishek

They have it in PPPt object and also in WordML so why not have it here as
well.

Any ways I have started using WordML and it seems to ive me almost
everything though have to work hard on understanding it and then
implementing.

thanks for the response

Abhishek
 

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