Reply
 
Thread Tools Display Modes
  #1   Report Post  
hstijnen
 
Posts: n/a
Default How to make listing of table captions?

Hi,
I would like to make a form for cross referencing to tables. I've made such
form for headings and used the code:
myHeadings = ActiveDocument.GetCrossReferenceItems(wdRefTypeHea ding)
giving an array with all headings in the document.

Is there a corresponding argument for (table) captions?

In Help are only mentioned wdRefTypeBookmark, wdRefTypeEndnote,
wdRefTypeFootnote, wdRefTypeHeading, wdRefTypeNumberedItem. However, in
method InsertCrossReference I see for argument ReferenceType the constant
wdCaptionTable. Ther should be a corresponding argument for
GetCrossReferenceItems.

  #2   Report Post  
Cindy M -WordMVP-
 
Posts: n/a
Default

Hi ?B?aHN0aWpuZW4=?=,

You'd probably have gotten a quicker response in a word.vba group...

What I might do, in this case, is search for the SEQ fields that number the
captions (assuming you've numbered them). Each numbering set has a unique
indentifier (name). So, you could search the document's range (with the field
codes on, or with TextRetrievalMode set to include field codes) for SEQ
[identifier], then pick up the paragraph in which the found range is located.

I would like to make a form for cross referencing to tables. I've made such
form for headings and used the code:
myHeadings = ActiveDocument.GetCrossReferenceItems(wdRefTypeHea ding)
giving an array with all headings in the document.

Is there a corresponding argument for (table) captions?

In Help are only mentioned wdRefTypeBookmark, wdRefTypeEndnote,
wdRefTypeFootnote, wdRefTypeHeading, wdRefTypeNumberedItem. However, in
method InsertCrossReference I see for argument ReferenceType the constant
wdCaptionTable. Ther should be a corresponding argument for
GetCrossReferenceItems.


Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :-)

  #3   Report Post  
hstijnen
 
Posts: n/a
Default

Thanks, Cindy,
I've already found my answer by trial and error:
myTables = ActiveDocument.GetCrossReferenceItems(wdCaptionTab le)
gives me the desired list. (I expected something like wdRefTypeCaptionTable)

Regards,

Henk

"Cindy M -WordMVP-" wrote:

Hi ?B?aHN0aWpuZW4=?=,

You'd probably have gotten a quicker response in a word.vba group...

What I might do, in this case, is search for the SEQ fields that number the
captions (assuming you've numbered them). Each numbering set has a unique
indentifier (name). So, you could search the document's range (with the field
codes on, or with TextRetrievalMode set to include field codes) for SEQ
[identifier], then pick up the paragraph in which the found range is located.

I would like to make a form for cross referencing to tables. I've made such
form for headings and used the code:
myHeadings = ActiveDocument.GetCrossReferenceItems(wdRefTypeHea ding)
giving an array with all headings in the document.

Is there a corresponding argument for (table) captions?

In Help are only mentioned wdRefTypeBookmark, wdRefTypeEndnote,
wdRefTypeFootnote, wdRefTypeHeading, wdRefTypeNumberedItem. However, in
method InsertCrossReference I see for argument ReferenceType the constant
wdCaptionTable. Ther should be a corresponding argument for
GetCrossReferenceItems.


Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :-)


Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Item in Table of Contents throw off numbering Robert McN Page Layout 4 January 27th 05 12:50 AM
How do I make the Table of Content link work? Lei Microsoft Word Help 2 January 17th 05 09:51 PM
Dragging table column resets Sedonakids Tables 0 January 12th 05 01:11 AM
Row height problem with table in table Stephanie T. Tables 0 November 23rd 04 03:35 PM
table caption numbering scottkinsey Tables 1 November 11th 04 11:47 AM


All times are GMT +1. The time now is 04:59 PM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"