#1
|
|||
|
|||
Highlight and put bookmark on the closest field to the cursor
I found myself selecting a number like 2 that is a caption of figure or table and putting bookmark on it a lot of times. I am wondering if I can have a code that make me able to just put the cursor in the line that the caption is located that the code finds the closest field to the cursor position, then select it and then run the bookmark command that shows the window waiting for entering the bookmark name? it looks like I am asking a lot for a macro, does't it?
|
#2
|
|||
|
|||
What if I just want to find the field in the current paragraph. Is it possible please?
|
#3
|
||||
|
||||
Hi b0x4it,
Why do you want to add a bookmark to a Caption? You can already cross-reference them via Insert|Cross-reference.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#4
|
|||
|
|||
For two reasons:
1. if I have 100 equations and I want to cross reference them, then I have to first jump to the equation and find out what is the number of its caption e.g. 37 or 59 and then again get back to where I was writing. If I put a bookmark on the caption, then I can put a name i.e. force_relation and I can find it in the list of all bookmarks quickly. 2. I found that if I want to use cross referencing for two or more captions like: ... as shown in Figures 1 and 2 ... then I have change the field code for those captions to { REF _Ref218925266 \# 0 \h }. Since I am not sure which of the caption would be called in the remaining of my text, then I have to change them all to get rid of the text before and after captions (label and caption). so I prefer to put bookmark on all captions and specify a name to them all. If I am doing wrong please let me know what is the more logical way to do it. and if what I am doing is right, please specify how I can find a field in the current line or paragraph or table and put a bookmark on it. |
#5
|
||||
|
||||
Quote:
Quote:
I believe the '{ REF _Ref218925266 \# 0 \h }' is derived from: http://sbarnhill.mvps.org/wordfaqs/combinexrefs.htm
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#6
|
|||
|
|||
You are right! Thank you so much for explaining this to me. It saves me lots of time. I really appreciate all you helps.
What is the main different between {QUOTE 'Caption' \* Arabic} or {QUOTE 'Caption' \# 0} ? what is that 0 for? I know that * defines type of numbering, but what is # for please? When I change them to {REF _Ref293660174 \h \# 0} it shows 01, do I have to put \# 0 before \h? When I use {QUOTE _Ref293660174 \# 0} it just shows me _Ref293660174, did you type QUOTE instead of REF incorrectly? |
#7
|
||||
|
||||
Hi b0x4it,
There is no material difference between {QUOTE 'Caption' \* Arabic} and {QUOTE 'Caption' \# 0}. The \* and \# are field switches. The \* gives access to a range of predefined options (eg \* Arabic, \* Roman) and the \# specifies a numeric output. If you're using a cross-refernce like {REF _Ref293660174 \h}, the \# 0 must go before the \h (ie {REF _Ref293660174 \# 0 \h}. The \h switch is a hyperlink switch and enables you to click on the cross-reference and go to its source.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#8
|
|||
|
|||
When I use {QUOTE _Ref293660174 \# 0} it just shows me _Ref293660174, did you type QUOTE instead of REF incorrectly? Does QUOTE work for captions too?
one last question please what is that 0 after \# for? can it be any number or it has to be just 0? |
#9
|
||||
|
||||
Hi b0x4it,
I didn't say to use {QUOTE _Ref293660174 \# 0}; I suggested {QUOTE 'Caption' \# 0}. If you've got the field code display toggled on, that would be equivalent to: {QUOTE {REF _Ref293660174 \h} \# 0} where the field brace pairs (ie '{ }') are created via Ctrl-F9.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#10
|
|||
|
|||
It works, thank you, but I think it is much easier to just add \# 0 before \h in the REF field.
I was not thinking clearly, because the problem with finding the right equation captions to make a cross-reference still exist, because there no label and caption for equations captions that are basically just numbers. If there are lots of equations in a long document, then it would be too hard to find the right equation to put cross-reference for it, except I put a bookmark and make a name for each of them. Do you have any other genius suggestion please? |
#11
|
||||
|
||||
Hi b0x4it,
That's OK - I was just letting you know there are other ways of dealing with the problem.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#12
|
|||
|
|||
So if I want to have a name instead of just the numbers in the list of equation captions, the only way is to put a bookmark with a specific name of the equation caption. Is there any other way of putting a name for equation caption, without changing the equation number or adding label to it?
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
VBA to insert Bookmark | rockwellsba | Word VBA | 2 | 05-31-2011 01:07 AM |
Bookmark Classification | DrDoom | Word | 0 | 06-29-2010 07:08 AM |
Multi Line Bookmark | streng | Word | 3 | 07-13-2009 07:54 AM |
Bookmark to another document | spqr | Word | 3 | 06-26-2009 04:51 AM |
find - reading highlight - highlight all / highlight doesn't stick when saved | bobk544 | Word | 3 | 04-15-2009 03:31 PM |