Home |
Search |
Today's Posts |
#1
|
|||
|
|||
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
|
|||
|
|||
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
|
|||
|
|||
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 | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Item in Table of Contents throw off numbering | Page Layout | |||
How do I make the Table of Content link work? | Microsoft Word Help | |||
Dragging table column resets | Tables | |||
Row height problem with table in table | Tables | |||
table caption numbering | Tables |