Group:  Microsoft Word ยป microsoft.public.word.numbering
Thread: Copy to find-and-replace without numbering

DotNetBag
.NET Development Newsgroups

HTVi
TV Discussion Newsgroups

Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
Rising Antivirus 2006

Copy to find-and-replace without numbering
Craig 22.07.2006 22:09:01
When I select text from any kind of numbered list and paste it into either
the "find what" or "replace with" fiields, it brings the numbering along with
it; this is happening with "bulleted", "numbered", and "outline numberd"
lists. This behavior only occurs when the very first character in the line
(after the numbering) is included in the copy; inclusion of the paragraph
mark at the end of the line makes no difference one way or the other - only
the inclusion of the first character in the line triggers this behavior.

I use outline-numbered lists extensively in my work, and I have to find and
replace phrases, etc., many times a day. This behavior requires to me to
always delete the numbering portion of the text (in the find/replace dialog)
before continuing with my task. It's driving me absolutely wild!

Please, please ... how do I make it stop?

Craig [ at ] Hewlett-Packard

Re: Copy to find-and-replace without numbering
"John McGhie [MVP - Word and Word Macintosh]" <john[ at ]mcghie.name> 23.07.2006 01:04:24
Hi Craig:

{Chortle} You can't make that one stop! You're being hit by a kludge to a
work-around caused by the fact that someone complained that when they
copy/pasted, they *didn't* get the numbers.

When you copy, Word sets a hidden bookmark to define the range you selected,
since it doesn't yet know what format you will paste in. When you paste,
Word identifies the format of the destination, calls the text converter
appropriate to the destination format, and hands it the reference from the
clipboard. The clipboard reference resolves to a text range. Word then
inspects the outer container to see if there was a list format: if there
was, it retrieves that too, converts the whole string and injects it at the
destination.

The macro to defeat this behaviour is extremely complex! Which means there
will always be instances where it "doesn't work".

If you have strong VBA skills, let me know and I will send you a foundation
macro that you can play with to get it doing what you want. If you don't
understand VBA string processing, forget it: it will take you too long
fiddling around to be worth it.

Cheers

On 23/7/06 8:09 AM, in article
63A9D1B2-A0BA-457E-BF57-25ED7C82D3BF[ at ]microsoft.com, "Craig"
<Craig[ at ]discussions.microsoft.com> wrote:

[Quoted Text]
> When I select text from any kind of numbered list and paste it into either
> the "find what" or "replace with" fiields, it brings the numbering along with
> it; this is happening with "bulleted", "numbered", and "outline numberd"
> lists. This behavior only occurs when the very first character in the line
> (after the numbering) is included in the copy; inclusion of the paragraph
> mark at the end of the line makes no difference one way or the other - only
> the inclusion of the first character in the line triggers this behavior.
>
> I use outline-numbered lists extensively in my work, and I have to find and
> replace phrases, etc., many times a day. This behavior requires to me to
> always delete the numbering portion of the text (in the find/replace dialog)
> before continuing with my task. It's driving me absolutely wild!
>
> Please, please ... how do I make it stop?
>
> Craig [ at ] Hewlett-Packard
>

--

Please reply to the newsgroup to maintain the thread. Please do not email
me unless I ask you to.

John McGhie <john[ at ]mcghie.name>
Microsoft MVP, Word and Word for Macintosh. Consultant Technical Writer
Sydney, Australia +61 (0) 4 1209 1410

Re: Copy to find-and-replace without numbering
Craig 23.07.2006 02:59:01
Hi John,
{Groan} Thanks for a very complete answer to my question. Not the answer I
wanted to hear, of course, but at least I know where I stand now. My VBA
skills are nowhere near what is needed to code for this, so you don't need to
send me the macro - thanks for offering, though.

Thanks much,
Craig

======================================
"John McGhie [MVP - Word and Word Macinto" wrote:

[Quoted Text]
> Hi Craig:
>
> {Chortle} You can't make that one stop! You're being hit by a kludge to a
> work-around caused by the fact that someone complained that when they
> copy/pasted, they *didn't* get the numbers.
>
> When you copy, Word sets a hidden bookmark to define the range you selected,
> since it doesn't yet know what format you will paste in. When you paste,
> Word identifies the format of the destination, calls the text converter
> appropriate to the destination format, and hands it the reference from the
> clipboard. The clipboard reference resolves to a text range. Word then
> inspects the outer container to see if there was a list format: if there
> was, it retrieves that too, converts the whole string and injects it at the
> destination.
>
> The macro to defeat this behaviour is extremely complex! Which means there
> will always be instances where it "doesn't work".
>
> If you have strong VBA skills, let me know and I will send you a foundation
> macro that you can play with to get it doing what you want. If you don't
> understand VBA string processing, forget it: it will take you too long
> fiddling around to be worth it.
>
> Cheers
>
> On 23/7/06 8:09 AM, in article
> 63A9D1B2-A0BA-457E-BF57-25ED7C82D3BF[ at ]microsoft.com, "Craig"
> <Craig[ at ]discussions.microsoft.com> wrote:
>
> > When I select text from any kind of numbered list and paste it into either
> > the "find what" or "replace with" fiields, it brings the numbering along with
> > it; this is happening with "bulleted", "numbered", and "outline numberd"
> > lists. This behavior only occurs when the very first character in the line
> > (after the numbering) is included in the copy; inclusion of the paragraph
> > mark at the end of the line makes no difference one way or the other - only
> > the inclusion of the first character in the line triggers this behavior.
> >
> > I use outline-numbered lists extensively in my work, and I have to find and
> > replace phrases, etc., many times a day. This behavior requires to me to
> > always delete the numbering portion of the text (in the find/replace dialog)
> > before continuing with my task. It's driving me absolutely wild!
> >
> > Please, please ... how do I make it stop?
> >
> > Craig [ at ] Hewlett-Packard
> >
>
> --
>
> Please reply to the newsgroup to maintain the thread. Please do not email
> me unless I ask you to.
>
> John McGhie <john[ at ]mcghie.name>
> Microsoft MVP, Word and Word for Macintosh. Consultant Technical Writer
> Sydney, Australia +61 (0) 4 1209 1410
>
>
Re: Copy to find-and-replace without numbering
"Shauna Kelly" <ShaunaKelly[ at ]SendNoSpamToShaunaKelly.com> 23.07.2006 12:24:05
Hi Craig

I share your frustration! Your post has prompted me to finish off some notes
I started a while ago. The code on this page may alleviate the frustration:

How to get Word to automatically fill the Edit > Find and Edit > Replace
boxes with the selected text
http://www.shaunakelly.com/word/defaulteditfind/

Hope this helps.

Shauna Kelly. Microsoft MVP.
http://www.shaunakelly.com/word


"Craig" <Craig[ at ]discussions.microsoft.com> wrote in message
news:F7C62221-82B3-49DE-BECC-B30DCEDD13C6[ at ]microsoft.com...
[Quoted Text]
> Hi John,
> {Groan} Thanks for a very complete answer to my question. Not the answer
> I
> wanted to hear, of course, but at least I know where I stand now. My VBA
> skills are nowhere near what is needed to code for this, so you don't need
> to
> send me the macro - thanks for offering, though.
>
> Thanks much,
> Craig
>
> ======================================
> "John McGhie [MVP - Word and Word Macinto" wrote:
>
>> Hi Craig:
>>
>> {Chortle} You can't make that one stop! You're being hit by a kludge to
>> a
>> work-around caused by the fact that someone complained that when they
>> copy/pasted, they *didn't* get the numbers.
>>
>> When you copy, Word sets a hidden bookmark to define the range you
>> selected,
>> since it doesn't yet know what format you will paste in. When you paste,
>> Word identifies the format of the destination, calls the text converter
>> appropriate to the destination format, and hands it the reference from
>> the
>> clipboard. The clipboard reference resolves to a text range. Word then
>> inspects the outer container to see if there was a list format: if there
>> was, it retrieves that too, converts the whole string and injects it at
>> the
>> destination.
>>
>> The macro to defeat this behaviour is extremely complex! Which means
>> there
>> will always be instances where it "doesn't work".
>>
>> If you have strong VBA skills, let me know and I will send you a
>> foundation
>> macro that you can play with to get it doing what you want. If you don't
>> understand VBA string processing, forget it: it will take you too long
>> fiddling around to be worth it.
>>
>> Cheers
>>
>> On 23/7/06 8:09 AM, in article
>> 63A9D1B2-A0BA-457E-BF57-25ED7C82D3BF[ at ]microsoft.com, "Craig"
>> <Craig[ at ]discussions.microsoft.com> wrote:
>>
>> > When I select text from any kind of numbered list and paste it into
>> > either
>> > the "find what" or "replace with" fiields, it brings the numbering
>> > along with
>> > it; this is happening with "bulleted", "numbered", and "outline
>> > numberd"
>> > lists. This behavior only occurs when the very first character in the
>> > line
>> > (after the numbering) is included in the copy; inclusion of the
>> > paragraph
>> > mark at the end of the line makes no difference one way or the other -
>> > only
>> > the inclusion of the first character in the line triggers this
>> > behavior.
>> >
>> > I use outline-numbered lists extensively in my work, and I have to find
>> > and
>> > replace phrases, etc., many times a day. This behavior requires to me
>> > to
>> > always delete the numbering portion of the text (in the find/replace
>> > dialog)
>> > before continuing with my task. It's driving me absolutely wild!
>> >
>> > Please, please ... how do I make it stop?
>> >
>> > Craig [ at ] Hewlett-Packard
>> >
>>
>> --
>>
>> Please reply to the newsgroup to maintain the thread. Please do not
>> email
>> me unless I ask you to.
>>
>> John McGhie <john[ at ]mcghie.name>
>> Microsoft MVP, Word and Word for Macintosh. Consultant Technical Writer
>> Sydney, Australia +61 (0) 4 1209 1410
>>
>>


Re: Copy to find-and-replace without numbering
"John McGhie [MVP - Word and Word Macintosh]" <john[ at ]mcghie.name> 24.07.2006 08:48:44
Hi Craig:

Don't you love the way Shauna proves that I was wrong without actually
*saying* so? Young lady, you have a career in the Diplomatic Service ahead
of you...

Craig: Shauna's macro is very simple: you could use that one easily.

Shauna: I could have sworn that last time I tried that, I got the numbering
as well. I've obviously had a brain-fade...

Cheers

On 23/7/06 10:24 PM, in article #P4T2MlrGHA.1796[ at ]TK2MSFTNGP03.phx.gbl,
"Shauna Kelly" <ShaunaKelly[ at ]SendNoSpamToShaunaKelly.com> wrote:

[Quoted Text]
> Hi Craig
>
> I share your frustration! Your post has prompted me to finish off some notes
> I started a while ago. The code on this page may alleviate the frustration:
>
> How to get Word to automatically fill the Edit > Find and Edit > Replace
> boxes with the selected text
> http://www.shaunakelly.com/word/defaulteditfind/
>
> Hope this helps.
>
> Shauna Kelly. Microsoft MVP.
> http://www.shaunakelly.com/word
>
>
> "Craig" <Craig[ at ]discussions.microsoft.com> wrote in message
> news:F7C62221-82B3-49DE-BECC-B30DCEDD13C6[ at ]microsoft.com...
>> Hi John,
>> {Groan} Thanks for a very complete answer to my question. Not the answer
>> I
>> wanted to hear, of course, but at least I know where I stand now. My VBA
>> skills are nowhere near what is needed to code for this, so you don't need
>> to
>> send me the macro - thanks for offering, though.
>>
>> Thanks much,
>> Craig
>>
>> ======================================
>> "John McGhie [MVP - Word and Word Macinto" wrote:
>>
>>> Hi Craig:
>>>
>>> {Chortle} You can't make that one stop! You're being hit by a kludge to
>>> a
>>> work-around caused by the fact that someone complained that when they
>>> copy/pasted, they *didn't* get the numbers.
>>>
>>> When you copy, Word sets a hidden bookmark to define the range you
>>> selected,
>>> since it doesn't yet know what format you will paste in. When you paste,
>>> Word identifies the format of the destination, calls the text converter
>>> appropriate to the destination format, and hands it the reference from
>>> the
>>> clipboard. The clipboard reference resolves to a text range. Word then
>>> inspects the outer container to see if there was a list format: if there
>>> was, it retrieves that too, converts the whole string and injects it at
>>> the
>>> destination.
>>>
>>> The macro to defeat this behaviour is extremely complex! Which means
>>> there
>>> will always be instances where it "doesn't work".
>>>
>>> If you have strong VBA skills, let me know and I will send you a
>>> foundation
>>> macro that you can play with to get it doing what you want. If you don't
>>> understand VBA string processing, forget it: it will take you too long
>>> fiddling around to be worth it.
>>>
>>> Cheers
>>>
>>> On 23/7/06 8:09 AM, in article
>>> 63A9D1B2-A0BA-457E-BF57-25ED7C82D3BF[ at ]microsoft.com, "Craig"
>>> <Craig[ at ]discussions.microsoft.com> wrote:
>>>
>>>> When I select text from any kind of numbered list and paste it into
>>>> either
>>>> the "find what" or "replace with" fiields, it brings the numbering
>>>> along with
>>>> it; this is happening with "bulleted", "numbered", and "outline
>>>> numberd"
>>>> lists. This behavior only occurs when the very first character in the
>>>> line
>>>> (after the numbering) is included in the copy; inclusion of the
>>>> paragraph
>>>> mark at the end of the line makes no difference one way or the other -
>>>> only
>>>> the inclusion of the first character in the line triggers this
>>>> behavior.
>>>>
>>>> I use outline-numbered lists extensively in my work, and I have to find
>>>> and
>>>> replace phrases, etc., many times a day. This behavior requires to me
>>>> to
>>>> always delete the numbering portion of the text (in the find/replace
>>>> dialog)
>>>> before continuing with my task. It's driving me absolutely wild!
>>>>
>>>> Please, please ... how do I make it stop?
>>>>
>>>> Craig [ at ] Hewlett-Packard
>>>>
>>>
>>> --
>>>
>>> Please reply to the newsgroup to maintain the thread. Please do not
>>> email
>>> me unless I ask you to.
>>>
>>> John McGhie <john[ at ]mcghie.name>
>>> Microsoft MVP, Word and Word for Macintosh. Consultant Technical Writer
>>> Sydney, Australia +61 (0) 4 1209 1410
>>>
>>>
>
>

--

Please reply to the newsgroup to maintain the thread. Please do not email
me unless I ask you to.

John McGhie <john[ at ]mcghie.name>
Microsoft MVP, Word and Word for Macintosh. Consultant Technical Writer
Sydney, Australia +61 (0) 4 1209 1410

Home | Search | Terms | Imprint | Contact
Newsgroups Reader - provided by WiredBox.Net