A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Word » Mailmerge
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Double quotes in Mail Merge



 
 
Thread Tools Display Modes
  #1  
Old May 4th, 2004, 04:37 AM
Guru
external usenet poster
 
Posts: n/a
Default Double quotes in Mail Merge

Hi,

How can I handle double quotes in Mail Merge?
I have datasource file which is like this

"Col1","Col2","Col3"
"abc","23"","xyz"

The above data fails to merge because the second value in
the second row i.e 23" has a double quote. How can I
handle this problem. I have replaced the double quote with
two double quotes and it worked for me. Is this the right
approach or is their a better way to solve this.

Also, will replacing the double quote with 2 double quotes
result in any mismatch between the columns.

Kindly advice.

Thanks
Guru
Ads
  #2  
Old May 4th, 2004, 08:48 AM
Graham Mayor
external usenet poster
 
Posts: n/a
Default Double quotes in Mail Merge

Not easily

The method which works is to open the data source document in Word

Use the replace function to perform a wildcard search for
"([!"])
replace with
\1

This will remove the field separation quotes, leaving the single quotes (it
will leave a final quote at the end of the document which must be removed by
hand if not required there).

Select the text and from the table menu, convert text to table.

Save the document and use it as a datasource for your merge.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




Guru wrote:
Hi,

How can I handle double quotes in Mail Merge?
I have datasource file which is like this

"Col1","Col2","Col3"
"abc","23"","xyz"

The above data fails to merge because the second value in
the second row i.e 23" has a double quote. How can I
handle this problem. I have replaced the double quote with
two double quotes and it worked for me. Is this the right
approach or is their a better way to solve this.

Also, will replacing the double quote with 2 double quotes
result in any mismatch between the columns.

Kindly advice.

Thanks
Guru



  #3  
Old May 5th, 2004, 09:07 AM
external usenet poster
 
Posts: n/a
Default Double quotes in Mail Merge

Hi,
But when I replace double quote with two double quotes,
word is able to merge.

If Hello!" is what I want to appear in my word letter
after merging then, if I replace Hello!" with Hello!""
word picks up Hello!" by converting two double quotes
into one.

Sample data file

Original data
"Name","Address"
"Guru","Bangalore " Address"

After correction
"Name","Address"
"Guru","Bangalore "" Address"

Now the address coloumn would appear as Bangalore "
Address in my letter.

Kindly advice

Thanks
Guru


-----Original Message-----
Not easily

The method which works is to open the data source

document in Word

Use the replace function to perform a wildcard search for
"([!"])
replace with
\1

This will remove the field separation quotes, leaving the

single quotes (it
will leave a final quote at the end of the document which

must be removed by
hand if not required there).

Select the text and from the table menu, convert text to

table.

Save the document and use it as a datasource for your

merge.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




Guru wrote:
Hi,

How can I handle double quotes in Mail Merge?
I have datasource file which is like this

"Col1","Col2","Col3"
"abc","23"","xyz"

The above data fails to merge because the second value

in
the second row i.e 23" has a double quote. How can I
handle this problem. I have replaced the double quote

with
two double quotes and it worked for me. Is this the

right
approach or is their a better way to solve this.

Also, will replacing the double quote with 2 double

quotes
result in any mismatch between the columns.

Kindly advice.

Thanks
Guru



.

  #4  
Old May 5th, 2004, 10:33 AM
Graham Mayor
external usenet poster
 
Posts: n/a
Default Double quotes in Mail Merge

Did you read *all* of what I wrote in response to your original query.
You need to turn the data file into a table.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




wrote:
Hi,
But when I replace double quote with two double quotes,
word is able to merge.

If Hello!" is what I want to appear in my word letter
after merging then, if I replace Hello!" with Hello!""
word picks up Hello!" by converting two double quotes
into one.

Sample data file

Original data
"Name","Address"
"Guru","Bangalore " Address"

After correction
"Name","Address"
"Guru","Bangalore "" Address"

Now the address coloumn would appear as Bangalore "
Address in my letter.

Kindly advice

Thanks
Guru


-----Original Message-----
Not easily

The method which works is to open the data source document in Word

Use the replace function to perform a wildcard search for
"([!"])
replace with
\1

This will remove the field separation quotes, leaving the single
quotes (it will leave a final quote at the end of the document which
must be removed by hand if not required there).

Select the text and from the table menu, convert text to table.

Save the document and use it as a datasource for your merge.

--

Graham Mayor - Word MVP

Web site
www.gmayor.com
Word MVP web site www.mvps.org/word




Guru wrote:
Hi,

How can I handle double quotes in Mail Merge?
I have datasource file which is like this

"Col1","Col2","Col3"
"abc","23"","xyz"

The above data fails to merge because the second value in
the second row i.e 23" has a double quote. How can I
handle this problem. I have replaced the double quote with
two double quotes and it worked for me. Is this the right
approach or is their a better way to solve this.

Also, will replacing the double quote with 2 double quotes
result in any mismatch between the columns.

Kindly advice.

Thanks
Guru



.




  #5  
Old May 5th, 2004, 01:22 PM
Guru
external usenet poster
 
Posts: n/a
Default Double quotes in Mail Merge

Hi,

Actually the methodology that I am following is slightly
different. I have a VB application, which creates the data
source file, and it uses the word API to merge the data
source file with the Mail Merge template. All this happens
programmatically without human intervention. So, I cannot
open the file and manipulate as suggested by you.

Now I have modified my program to replace all double
quotes with two double quotes, which in turn is taken as a
single double quote by Word.

Let me know if this approach is correct.

I can also send a sample template and data source file if
you need.


Thanks
Guru



-----Original Message-----
Did you read *all* of what I wrote in response to your

original query.
You need to turn the data file into a table.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




wrote:
Hi,
But when I replace double quote with two double quotes,
word is able to merge.

If Hello!" is what I want to appear in my word letter
after merging then, if I replace Hello!" with

Hello!""
word picks up Hello!" by converting two double quotes
into one.

Sample data file

Original data
"Name","Address"
"Guru","Bangalore " Address"

After correction
"Name","Address"
"Guru","Bangalore "" Address"

Now the address coloumn would appear as Bangalore "
Address in my letter.

Kindly advice

Thanks
Guru


-----Original Message-----
Not easily

The method which works is to open the data source

document in Word

Use the replace function to perform a wildcard search

for
"([!"])
replace with
\1

This will remove the field separation quotes, leaving

the single
quotes (it will leave a final quote at the end of the

document which
must be removed by hand if not required there).

Select the text and from the table menu, convert text

to table.

Save the document and use it as a datasource for your

merge.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




Guru wrote:
Hi,

How can I handle double quotes in Mail Merge?
I have datasource file which is like this

"Col1","Col2","Col3"
"abc","23"","xyz"

The above data fails to merge because the second

value in
the second row i.e 23" has a double quote. How can I
handle this problem. I have replaced the double quote

with
two double quotes and it worked for me. Is this the

right
approach or is their a better way to solve this.

Also, will replacing the double quote with 2 double

quotes
result in any mismatch between the columns.

Kindly advice.

Thanks
Guru


.




.

  #6  
Old May 5th, 2004, 01:50 PM
Graham Mayor
external usenet poster
 
Posts: n/a
Default Double quotes in Mail Merge

I see your problem, but I cannot get it to work unless I use a table for the
data source. Unless someone else has a plan, I cannot offer any alternative
suggestion.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




Guru wrote:
Hi,

Actually the methodology that I am following is slightly
different. I have a VB application, which creates the data
source file, and it uses the word API to merge the data
source file with the Mail Merge template. All this happens
programmatically without human intervention. So, I cannot
open the file and manipulate as suggested by you.

Now I have modified my program to replace all double
quotes with two double quotes, which in turn is taken as a
single double quote by Word.

Let me know if this approach is correct.

I can also send a sample template and data source file if
you need.


Thanks
Guru



-----Original Message-----
Did you read *all* of what I wrote in response to your original
query. You need to turn the data file into a table.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




wrote:
Hi,
But when I replace double quote with two double quotes,
word is able to merge.

If Hello!" is what I want to appear in my word letter
after merging then, if I replace Hello!" with Hello!""
word picks up Hello!" by converting two double quotes
into one.

Sample data file

Original data
"Name","Address"
"Guru","Bangalore " Address"

After correction
"Name","Address"
"Guru","Bangalore "" Address"

Now the address coloumn would appear as Bangalore "
Address in my letter.

Kindly advice

Thanks
Guru


-----Original Message-----
Not easily

The method which works is to open the data source document in Word

Use the replace function to perform a wildcard search for
"([!"])
replace with
\1

This will remove the field separation quotes, leaving the single
quotes (it will leave a final quote at the end of the document
which must be removed by hand if not required there).

Select the text and from the table menu, convert text to table.

Save the document and use it as a datasource for your merge.

--

Graham Mayor - Word MVP

Web site
www.gmayor.com
Word MVP web site www.mvps.org/word




Guru wrote:
Hi,

How can I handle double quotes in Mail Merge?
I have datasource file which is like this

"Col1","Col2","Col3"
"abc","23"","xyz"

The above data fails to merge because the second

value in
the second row i.e 23" has a double quote. How can I
handle this problem. I have replaced the double quote with
two double quotes and it worked for me. Is this the right
approach or is their a better way to solve this.

Also, will replacing the double quote with 2 double quotes
result in any mismatch between the columns.

Kindly advice.

Thanks
Guru


.




.



  #7  
Old May 5th, 2004, 03:08 PM
Guru
external usenet poster
 
Posts: n/a
Default Double quotes in Mail Merge

Thatz fine..Not a problem.

Microsoft has actually published a article on this issue,
you can have a look at this one
http://support.microsoft.com/default.aspx?scid=kb;EN-
US;212358

Thanks
Guru


-----Original Message-----
I see your problem, but I cannot get it to work unless I

use a table for the
data source. Unless someone else has a plan, I cannot

offer any alternative
suggestion.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




Guru wrote:
Hi,

Actually the methodology that I am following is slightly
different. I have a VB application, which creates the

data
source file, and it uses the word API to merge the data
source file with the Mail Merge template. All this

happens
programmatically without human intervention. So, I

cannot
open the file and manipulate as suggested by you.

Now I have modified my program to replace all double
quotes with two double quotes, which in turn is taken

as a
single double quote by Word.

Let me know if this approach is correct.

I can also send a sample template and data source file

if
you need.


Thanks
Guru



-----Original Message-----
Did you read *all* of what I wrote in response to your

original
query. You need to turn the data file into a table.

--

Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word




wrote:
Hi,
But when I replace double quote with two double

quotes,
word is able to merge.

If Hello!" is what I want to appear in my word

letter
after merging then, if I replace Hello!" with

Hello!""
word picks up Hello!" by converting two double

quotes
into one.

Sample data file

Original data
"Name","Address"
"Guru","Bangalore " Address"

After correction
"Name","Address"
"Guru","Bangalore "" Address"

Now the address coloumn would appear as Bangalore "
Address in my letter.

Kindly advice

Thanks
Guru


-----Original Message-----
Not easily

The method which works is to open the data source

document in Word

Use the replace function to perform a wildcard

search for
"([!"])
replace with
\1

This will remove the field separation quotes,

leaving the single
quotes (it will leave a final quote at the end of

the document
which must be removed by hand if not required there).

Select the text and from the table menu, convert

text to table.

Save the document and use it as a datasource for

your merge.

--

Graham Mayor - Word MVP

Web site
www.gmayor.com
Word MVP web site www.mvps.org/word




Guru wrote:
Hi,

How can I handle double quotes in Mail Merge?
I have datasource file which is like this

"Col1","Col2","Col3"
"abc","23"","xyz"

The above data fails to merge because the second

value in
the second row i.e 23" has a double quote. How

can I
handle this problem. I have replaced the double

quote with
two double quotes and it worked for me. Is this the

right
approach or is their a better way to solve this.

Also, will replacing the double quote with 2 double

quotes
result in any mismatch between the columns.

Kindly advice.

Thanks
Guru


.



.



.

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 03:07 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
Copyright 2004-2019 OfficeFrustration.
The comments are property of their posters.