From: EM on
X-No-Archive: Yes

I frequently use the macro to extract acronyms into another document posted
in http://www.thedoctools.com/index.php?show=mt_acronyms_extract. Is there a
way to put the paragraph number in the third column instead of the page
number?

.Cell(n + 1, 1).Range.Text = strAcronym
'Insert page number in column 3
.Cell(n + 1, 3).Range.Text =
oRange.Information(wdActiveEndPageNumber)

Thanks in advance.




From: Doug Robbins - Word MVP on
Just what do you mean by the paragraph number?

Are the paragraphs numbered by the use of a style that includes the
numbering?

Is it the number of the paragraph on that page where the first paragraph or
part paragraph on that page would be paragraph 1?

Is it the number of the paragraph in the document where the first paragraph
in the document will be paragraph 1?

--
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, originally posted via msnews.microsoft.com

"EM" <EM(a)nospam.discussions.com> wrote in message
news:eUzGv768KHA.5724(a)TK2MSFTNGP04.phx.gbl...
> X-No-Archive: Yes
>
> I frequently use the macro to extract acronyms into another document
> posted
> in http://www.thedoctools.com/index.php?show=mt_acronyms_extract. Is there
> a
> way to put the paragraph number in the third column instead of the page
> number?
>
> .Cell(n + 1, 1).Range.Text = strAcronym
> 'Insert page number in column 3
> .Cell(n + 1, 3).Range.Text =
> oRange.Information(wdActiveEndPageNumber)
>
> Thanks in advance.
>
>
>
>
From: EM on
X-No-Archive: Yes

>>Are the paragraphs numbered by the use of a style that includes the
numbering?
Is it the number of the paragraph in the document where the first paragraph
in the document will be paragraph 1?<<

Yes, the paragraphs are numbered with a style that includes the
numbering and the first paragraph in the document will be paragraph 1.

--



From: Doug Robbins - Word MVP on
Use:

oDoc_Source.ConvertNumberstoText

and then use:

.Cell(n + 1, 1).Range.Text = strAcronym
.Cell(n + 1, 3).Range.Text = Left(oRange.Paragraphs(1).Range,
InStr(oRange.Paragraphs(1).Range, Chr(9)))

At the end I would add:

oDoc_Source.Close savechanges:=wdDoNotSaveChanges

to close the source document without change of converting the numbers to
text.

--
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, originally posted via msnews.microsoft.com

"EM" <EM(a)nospam.discussions.com> wrote in message
news:#U0V2hD9KHA.3276(a)TK2MSFTNGP02.phx.gbl...
> X-No-Archive: Yes
>
>>>Are the paragraphs numbered by the use of a style that includes the
> numbering?
> Is it the number of the paragraph in the document where the first
> paragraph
> in the document will be paragraph 1?<<
>
> Yes, the paragraphs are numbered with a style that includes the
> numbering and the first paragraph in the document will be paragraph 1.
>
> --
>
>
>
From: EM on
X-No-Archive: Yes

Worked perfectly, Thanks a lot.

---

>>Use:

oDoc_Source.ConvertNumberstoText
and then use:
.Cell(n + 1, 1).Range.Text = strAcronym
.Cell(n + 1, 3).Range.Text = Left(oRange.Paragraphs(1).Range,
InStr(oRange.Paragraphs(1).Range, Chr(9)))<<