#1
|
|||
|
|||
extending a selection
Hi,
Not quite sure how to achieve this. I'm searching for a reference or references, they all begin Ref: followed by two digits. This is followed by various characters, and I need to extend the selection to include these. I assume I need to use "With Selection", and what I want to do is to extend the selection until there is a punctuation mark, or a space. I started by just adding 7 to the .end of a range, but that excluded some and sometimes included bits I didn't want. I've not included any of my code as I'm not entirely sure where to start with this, Thanks, David. |
#2
|
||||
|
||||
Assuming the 'various characters' don't include spaces, etc., with a wildcard Find:
<Ref:[0-9]{2}*>
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#3
|
|||
|
|||
Far more effective! Probably breaking a rule here, but how would I paste these references into a new blank document. Not worried about saving,
Many thanks, David. |
#4
|
||||
|
||||
See, for example:
https://www.msofficeforums.com/128621-post2.html https://www.msofficeforums.com/118412-post2.html
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#5
|
|||
|
|||
Perfect!
Thanks, DAvid. |
Tags |
extend, selection, vba |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
typing "scr" and problem with "extending selection" | danielmatt | Word | 16 | 07-21-2019 12:31 PM |
Extending or shortening an existing line | ironman1159 | Drawing and Graphics | 0 | 07-01-2019 03:06 PM |
Resource not getting enough hours allocated to them, therefore extending duration | joday48 | Project | 1 | 08-01-2014 08:54 AM |
Extending Table or Textbox to Next Page | Jazz43 | Word | 3 | 10-17-2012 01:43 AM |
extending an arrow? | danjohnson10 | PowerPoint | 1 | 04-23-2011 04:39 PM |