Problem with difference between sentences and lines

  • Thread starter Peter van de Kerkhof
  • Start date
P

Peter van de Kerkhof

Hi,



With the help of some of you I am able to read word (in-line) comment with
page and line numbers.

I can store it and put it back in a document again.

I have even fixed the problem with shifting lines (and pages) after comment
insert.



But I have another problem.

Reading comment is page, line related, inserting is Sentence related.

(Reading must stay page, line related for 'other' reasons!)



There are times when there are 2 sentences on 1 line.

In that case my comment indicator is (sometimes?) visible on the next/wrong
line.



The frequency of occurrence is limited, so it is no big issue, but I like it
to be perfect.



So the simple question now is:

How can I step thru a word document using lines numbers?

(and still insert my comment using line numbers)



Regards Peter
 
M

martinique

Unfortunately, you're getting further and further away from the object model
on which Word is based. The concept of 'line' is not part of the model (nor,
for that matter, is 'page') -- these are artefacts of Word's pagination, and
are considered to be dynamic features of the document, nor inherent
properties.

If this is a serious application you're creating, I think you maybe need to
stop and rethink your design before you find your self wading through a
deepening swamp.

The best option available (and it's fairly ugly) is to step through the
document in small increments (sentence, word, or character) checking the
line number each time.
 
P

Peter van de Kerkhof

Martinique
It is (part of) a serious (small) application and I like to solve this,
object model or not.
I understand that a solution based on the 'word' object model would be
better etc.
but it seems not do-able.
The best option available (and it's fairly ugly) is to step through the
document in small increments (sentence, word, or character) checking the
line number each time.
It seems (to my knowledge) that empty lines a skipped when I uses sentences,
thats why this
was not one of my favourites solutions.
So sentence 1 can be on line5 and sentence 2 on line 10

The solution I'm now working on is positioning the cursor at the bottom of
the document
and do a 'line-up' command, yes checking line and page number again and do
another 'line-up' until I reached line 1 of page 1

Something like this was sugegsted in an answer of a simular question.
A simple 'record macro' in word gave me the commands to use.

Thanks for your advice
 

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