Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Mary Ann Mary Ann is offline
external usenet poster
 
Posts: 82
Default Email merge attach file

Is it possible to attach a file when doing an email merge?
  #2   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default Email merge - attach file

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?



  #3   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Mary Ann Mary Ann is offline
external usenet poster
 
Posts: 82
Default Email merge - attach file

Thanks Doug - I don't work with VB so I guess for me the answer is that I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?




  #4   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default Email merge - attach file

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions precisely (to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer is that I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?






  #5   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Mary Ann Mary Ann is offline
external usenet poster
 
Posts: 82
Default Email merge - attach file

Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions precisely (to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer is that I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?








  #6   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default Email merge - attach file

Sorry, yes it is. I guess I was half awake when I read "I don't work with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it, see
the article "What do I do with macros sent to me by other newsgroup readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer is that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?








  #7   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Mary Ann Mary Ann is offline
external usenet poster
 
Posts: 82
Default Email merge - attach file

Thanks Doug - useful & reassuring!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't work with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it, see
the article "What do I do with macros sent to me by other newsgroup readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer is that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?









  #8   Report Post  
Posted to microsoft.public.word.mailmerge.fields
tammy tammy is offline
external usenet poster
 
Posts: 107
Default Email merge - attach file

Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided. However,
when I get to the part where I run the macro, I end up with a dialog box that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the message
means, and how to fix it? If I can get this email merge with an attachment to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't work with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it, see
the article "What do I do with macros sent to me by other newsgroup readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer is that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?









  #9   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Peter Jamieson Peter Jamieson is offline
external usenet poster
 
Posts: 4,582
Default Email merge - attach file

I'm not Doug, but you probably need to use the VB Editor's Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it (where nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided. However,
when I get to the part where I run the macro, I end up with a dialog box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the
message
means, and how to fix it? If I can get this email merge with an attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it,
see
the article "What do I do with macros sent to me by other newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?










  #10   Report Post  
Posted to microsoft.public.word.mailmerge.fields
tammy tammy is offline
external usenet poster
 
Posts: 107
Default Email merge - attach file

Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft Outlook 12.0
Object Library" is checked. In Word, where the macro is run from, there is no
option for "Microsoft Outlook 12.0 Object Library." There is a check next to
"Microsoft Office 12.0 Object Library" - this is also checked in OL. Since an
email merge from OL takes you to Word anyway, I **assumed** that is where the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly into the VB
window, but the article didn't indicate if something had to be modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it (where nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided. However,
when I get to the part where I run the macro, I end up with a dialog box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the
message
means, and how to fix it? If I can get this email merge with an attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it,
see
the article "What do I do with macros sent to me by other newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?













  #11   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Peter Jamieson Peter Jamieson is offline
external usenet poster
 
Posts: 4,582
Default Email merge - attach file

I **assumed** that is where the
macro had to be created.


That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word VBE's
Tools-References option? There can be hundreds of objects in the list -
e.g. on my system, that particular entry is about the 450th in the list.

It would be checked by defaul tin Outlook itself, but it would not be
checked (and therefore near the top of the list ) by default in Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft Outlook
12.0
Object Library" is checked. In Word, where the macro is run from, there is
no
option for "Microsoft Outlook 12.0 Object Library." There is a check next
to
"Microsoft Office 12.0 Object Library" - this is also checked in OL. Since
an
email merge from OL takes you to Word anyway, I **assumed** that is where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly into the
VB
window, but the article didn't indicate if something had to be modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it (where nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided.
However,
when I get to the part where I run the macro, I end up with a dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the
message
means, and how to fix it? If I can get this email merge with an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it,
see
the article "What do I do with macros sent to me by other newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?












  #12   Report Post  
Posted to microsoft.public.word.mailmerge.fields
tammy tammy is offline
external usenet poster
 
Posts: 107
Default Email merge - attach file

Hey! What did you do to my computer??!! How did you get that to magically
appear??

Thanks, again, Peter! My macro is working now, but only sending to the first
person in the table. I'll keep working at that.

You rock! Thanks!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.


That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word VBE's
Tools-References option? There can be hundreds of objects in the list -
e.g. on my system, that particular entry is about the 450th in the list.

It would be checked by defaul tin Outlook itself, but it would not be
checked (and therefore near the top of the list ) by default in Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft Outlook
12.0
Object Library" is checked. In Word, where the macro is run from, there is
no
option for "Microsoft Outlook 12.0 Object Library." There is a check next
to
"Microsoft Office 12.0 Object Library" - this is also checked in OL. Since
an
email merge from OL takes you to Word anyway, I **assumed** that is where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly into the
VB
window, but the article didn't indicate if something had to be modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it (where nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided.
However,
when I get to the part where I run the macro, I end up with a dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the
message
means, and how to fix it? If I can get this email merge with an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it,
see
the article "What do I do with macros sent to me by other newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?













  #13   Report Post  
Posted to microsoft.public.word.mailmerge.fields
tammy tammy is offline
external usenet poster
 
Posts: 107
Default Email merge - attach file

I got the email with an attachment to work! Thanks again to Peter and Doug
for the terrific, useful info.!

Have a great week!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.


That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word VBE's
Tools-References option? There can be hundreds of objects in the list -
e.g. on my system, that particular entry is about the 450th in the list.

It would be checked by defaul tin Outlook itself, but it would not be
checked (and therefore near the top of the list ) by default in Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft Outlook
12.0
Object Library" is checked. In Word, where the macro is run from, there is
no
option for "Microsoft Outlook 12.0 Object Library." There is a check next
to
"Microsoft Office 12.0 Object Library" - this is also checked in OL. Since
an
email merge from OL takes you to Word anyway, I **assumed** that is where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly into the
VB
window, but the article didn't indicate if something had to be modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it (where nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided.
However,
when I get to the part where I run the macro, I end up with a dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the
message
means, and how to fix it? If I can get this email merge with an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it,
see
the article "What do I do with macros sent to me by other newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?













  #14   Report Post  
Posted to microsoft.public.word.mailmerge.fields
tammy tammy is offline
external usenet poster
 
Posts: 107
Default Email merge - attach file

Hi Peter,

Yesterday I had this working without a hitch, but today I am running into
problems.

I have a data source that matches my directory exactly - same amount of
records and they all have an email addresses (same people in the source and
directory). When I run the macro, the email gets sent to everyone, but it
also keeps sending just the attachment to the last person in the directory.
So, that person receives the correct email with the message and attachment,
plus another email with just the attachment (but, no message). Any idea of
why that would be happening?

I was having a problem earlier of the email going out with the attachment,
but the "to" names did not match up to their respective "Dear *name*" in the
message. That is not happening anymore, and to tell you the truth, I've run
so many tests that I don't know how I fixed it. (If any of that made sense,
and you know why the source would not match up the names of the people
correctly, please please please let me know. That one had me baffled.)

Thanks for any suggestions on why the extra email would be going out with
just the attachment to one of the recipients. If I should post this question
to the Word group, please let me know.

Thanks, again! I thought I was done bugging you!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.


That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word VBE's
Tools-References option? There can be hundreds of objects in the list -
e.g. on my system, that particular entry is about the 450th in the list.

It would be checked by defaul tin Outlook itself, but it would not be
checked (and therefore near the top of the list ) by default in Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft Outlook
12.0
Object Library" is checked. In Word, where the macro is run from, there is
no
option for "Microsoft Outlook 12.0 Object Library." There is a check next
to
"Microsoft Office 12.0 Object Library" - this is also checked in OL. Since
an
email merge from OL takes you to Word anyway, I **assumed** that is where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly into the
VB
window, but the article didn't indicate if something had to be modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it (where nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided.
However,
when I get to the part where I run the macro, I end up with a dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the
message
means, and how to fix it? If I can get this email merge with an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of it,
see
the article "What do I do with macros sent to me by other newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?













  #15   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Peter Jamieson Peter Jamieson is offline
external usenet poster
 
Posts: 4,582
Default Email merge - attach file

I expect I'm guessing more than Doug would be at this point, but...
a. you should be able to look at the table that you create when you do your
catalog/directory merge.
- how many rows does it have?
- does the last row have non-blank values in both column 1 and column 2?
b. you should also be able to save the document produced by the second
mailmerge. If you click right at the end of the document
- how many sections does it have (you should be able to see int he Word
status bar)

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Yesterday I had this working without a hitch, but today I am running into
problems.

I have a data source that matches my directory exactly - same amount of
records and they all have an email addresses (same people in the source
and
directory). When I run the macro, the email gets sent to everyone, but it
also keeps sending just the attachment to the last person in the
directory.
So, that person receives the correct email with the message and
attachment,
plus another email with just the attachment (but, no message). Any idea of
why that would be happening?

I was having a problem earlier of the email going out with the attachment,
but the "to" names did not match up to their respective "Dear *name*" in
the
message. That is not happening anymore, and to tell you the truth, I've
run
so many tests that I don't know how I fixed it. (If any of that made
sense,
and you know why the source would not match up the names of the people
correctly, please please please let me know. That one had me baffled.)

Thanks for any suggestions on why the extra email would be going out with
just the attachment to one of the recipients. If I should post this
question
to the Word group, please let me know.

Thanks, again! I thought I was done bugging you!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.


That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word VBE's
Tools-References option? There can be hundreds of objects in the list -
e.g. on my system, that particular entry is about the 450th in the list.

It would be checked by defaul tin Outlook itself, but it would not be
checked (and therefore near the top of the list ) by default in Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft Outlook
12.0
Object Library" is checked. In Word, where the macro is run from, there
is
no
option for "Microsoft Outlook 12.0 Object Library." There is a check
next
to
"Microsoft Office 12.0 Object Library" - this is also checked in OL.
Since
an
email merge from OL takes you to Word anyway, I **assumed** that is
where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly into
the
VB
window, but the article didn't indicate if something had to be modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it (where
nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided.
However,
when I get to the part where I run the macro, I end up with a dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the
message
means, and how to fix it? If I can get this email merge with an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't
work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of
it,
see
the article "What do I do with macros sent to me by other newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the
answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Is it possible to attach a file when doing an email merge?
















  #16   Report Post  
Posted to microsoft.public.word.mailmerge.fields
tammy tammy is offline
external usenet poster
 
Posts: 107
Default Email merge - attach file

Hi Peter,

I knew it was probably a guessing game at this point. Thanks for giving me
some places to look.

My table is complete, with no extra characters or empty cells. The merged
document has the correct number of letters (four, in this example) after
merging to individual letters. However, there are a total of five sections,
instead of four. Word has automatically added an additional return at the end
of the last letter, and the extra return appears in section five. Word has
placed the extra return after a "continuous" section break in the last
letter. (All the other letters are separated with a "next page" section
break.)

I can't delete the extra return.

After noticing that, I returned to the merged emails from yesterday and
realized this did happen then, too. The last person received the correct
email message and attachment, plus an additional email with just the
attachment.

Do you think this is a question I should post to the Word group? I'm not so
sure it has anything to do with Outlook, or the macro to run the email with
attachment.

I really do appreciate the time you've taken with all of this. I also
checked both of your responses as "helpful" but haven't seen the green check
mark yet. Thanks, again!

"Peter Jamieson" wrote:

I expect I'm guessing more than Doug would be at this point, but...
a. you should be able to look at the table that you create when you do your
catalog/directory merge.
- how many rows does it have?
- does the last row have non-blank values in both column 1 and column 2?
b. you should also be able to save the document produced by the second
mailmerge. If you click right at the end of the document
- how many sections does it have (you should be able to see int he Word
status bar)

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Yesterday I had this working without a hitch, but today I am running into
problems.

I have a data source that matches my directory exactly - same amount of
records and they all have an email addresses (same people in the source
and
directory). When I run the macro, the email gets sent to everyone, but it
also keeps sending just the attachment to the last person in the
directory.
So, that person receives the correct email with the message and
attachment,
plus another email with just the attachment (but, no message). Any idea of
why that would be happening?

I was having a problem earlier of the email going out with the attachment,
but the "to" names did not match up to their respective "Dear *name*" in
the
message. That is not happening anymore, and to tell you the truth, I've
run
so many tests that I don't know how I fixed it. (If any of that made
sense,
and you know why the source would not match up the names of the people
correctly, please please please let me know. That one had me baffled.)

Thanks for any suggestions on why the extra email would be going out with
just the attachment to one of the recipients. If I should post this
question
to the Word group, please let me know.

Thanks, again! I thought I was done bugging you!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.

That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word VBE's
Tools-References option? There can be hundreds of objects in the list -
e.g. on my system, that particular entry is about the 450th in the list.

It would be checked by defaul tin Outlook itself, but it would not be
checked (and therefore near the top of the list ) by default in Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft Outlook
12.0
Object Library" is checked. In Word, where the macro is run from, there
is
no
option for "Microsoft Outlook 12.0 Object Library." There is a check
next
to
"Microsoft Office 12.0 Object Library" - this is also checked in OL.
Since
an
email merge from OL takes you to Word anyway, I **assumed** that is
where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly into
the
VB
window, but the article didn't indicate if something had to be modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it (where
nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes an
attachment - thanks to the very helpful articles you've provided.
However,
when I get to the part where I run the macro, I end up with a dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what the
message
means, and how to fix it? If I can get this email merge with an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't
work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use of
it,
see
the article "What do I do with macros sent to me by other newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Thanks Doug - I don't work with VB so I guess for me the
answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Is it possible to attach a file when doing an email merge?















  #17   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default Email merge - attach file

I recently had that article updated and in doing so, an error crept into the
code of the macro.

The line of code

For j = 1 To Source.Sections.Count

should be

For j = 1 To Source.Sections.Count - 1


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Tammy" wrote in message
...
Hi Peter,

I knew it was probably a guessing game at this point. Thanks for giving me
some places to look.

My table is complete, with no extra characters or empty cells. The merged
document has the correct number of letters (four, in this example) after
merging to individual letters. However, there are a total of five
sections,
instead of four. Word has automatically added an additional return at the
end
of the last letter, and the extra return appears in section five. Word has
placed the extra return after a "continuous" section break in the last
letter. (All the other letters are separated with a "next page" section
break.)

I can't delete the extra return.

After noticing that, I returned to the merged emails from yesterday and
realized this did happen then, too. The last person received the correct
email message and attachment, plus an additional email with just the
attachment.

Do you think this is a question I should post to the Word group? I'm not
so
sure it has anything to do with Outlook, or the macro to run the email
with
attachment.

I really do appreciate the time you've taken with all of this. I also
checked both of your responses as "helpful" but haven't seen the green
check
mark yet. Thanks, again!

"Peter Jamieson" wrote:

I expect I'm guessing more than Doug would be at this point, but...
a. you should be able to look at the table that you create when you do
your
catalog/directory merge.
- how many rows does it have?
- does the last row have non-blank values in both column 1 and column
2?
b. you should also be able to save the document produced by the second
mailmerge. If you click right at the end of the document
- how many sections does it have (you should be able to see int he Word
status bar)

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Yesterday I had this working without a hitch, but today I am running
into
problems.

I have a data source that matches my directory exactly - same amount of
records and they all have an email addresses (same people in the source
and
directory). When I run the macro, the email gets sent to everyone, but
it
also keeps sending just the attachment to the last person in the
directory.
So, that person receives the correct email with the message and
attachment,
plus another email with just the attachment (but, no message). Any idea
of
why that would be happening?

I was having a problem earlier of the email going out with the
attachment,
but the "to" names did not match up to their respective "Dear *name*"
in
the
message. That is not happening anymore, and to tell you the truth, I've
run
so many tests that I don't know how I fixed it. (If any of that made
sense,
and you know why the source would not match up the names of the people
correctly, please please please let me know. That one had me baffled.)

Thanks for any suggestions on why the extra email would be going out
with
just the attachment to one of the recipients. If I should post this
question
to the Word group, please let me know.

Thanks, again! I thought I was done bugging you!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.

That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word VBE's
Tools-References option? There can be hundreds of objects in the
list -
e.g. on my system, that particular entry is about the 450th in the
list.

It would be checked by defaul tin Outlook itself, but it would not be
checked (and therefore near the top of the list ) by default in Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft
Outlook
12.0
Object Library" is checked. In Word, where the macro is run from,
there
is
no
option for "Microsoft Outlook 12.0 Object Library." There is a check
next
to
"Microsoft Office 12.0 Object Library" - this is also checked in OL.
Since
an
email merge from OL takes you to Word anyway, I **assumed** that is
where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly
into
the
VB
window, but the article didn't indicate if something had to be
modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it
(where
nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes
an
attachment - thanks to the very helpful articles you've provided.
However,
when I get to the part where I run the macro, I end up with a
dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what
the
message
means, and how to fix it? If I can get this email merge with an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't
work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use
of
it,
see
the article "What do I do with macros sent to me by other
newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Thanks Doug - I don't work with VB so I guess for me the
answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Is it possible to attach a file when doing an email
merge?

















  #18   Report Post  
Posted to microsoft.public.word.mailmerge.fields
tammy tammy is offline
external usenet poster
 
Posts: 107
Default Email merge - attach file

Hi Doug,

Thanks very much for the line of code! That fixed my problem.

The only other thing I saw was in the final count indicated in the dialog
box. For example, I sent two letters, but the dialog box indicated that three
were sent. My sent folder only shows two sent, which is what I wanted.

Is there something else I should change in the code, or will this be the
"norm"?

Thanks, again for the GREAT article!! Peter has been awesome walking me
through a couple of other things, too. Really appreciate people like you and
Peter! Thanks for the help!

"Doug Robbins - Word MVP" wrote:

I recently had that article updated and in doing so, an error crept into the
code of the macro.

The line of code

For j = 1 To Source.Sections.Count

should be

For j = 1 To Source.Sections.Count - 1


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Tammy" wrote in message
...
Hi Peter,

I knew it was probably a guessing game at this point. Thanks for giving me
some places to look.

My table is complete, with no extra characters or empty cells. The merged
document has the correct number of letters (four, in this example) after
merging to individual letters. However, there are a total of five
sections,
instead of four. Word has automatically added an additional return at the
end
of the last letter, and the extra return appears in section five. Word has
placed the extra return after a "continuous" section break in the last
letter. (All the other letters are separated with a "next page" section
break.)

I can't delete the extra return.

After noticing that, I returned to the merged emails from yesterday and
realized this did happen then, too. The last person received the correct
email message and attachment, plus an additional email with just the
attachment.

Do you think this is a question I should post to the Word group? I'm not
so
sure it has anything to do with Outlook, or the macro to run the email
with
attachment.

I really do appreciate the time you've taken with all of this. I also
checked both of your responses as "helpful" but haven't seen the green
check
mark yet. Thanks, again!

"Peter Jamieson" wrote:

I expect I'm guessing more than Doug would be at this point, but...
a. you should be able to look at the table that you create when you do
your
catalog/directory merge.
- how many rows does it have?
- does the last row have non-blank values in both column 1 and column
2?
b. you should also be able to save the document produced by the second
mailmerge. If you click right at the end of the document
- how many sections does it have (you should be able to see int he Word
status bar)

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Yesterday I had this working without a hitch, but today I am running
into
problems.

I have a data source that matches my directory exactly - same amount of
records and they all have an email addresses (same people in the source
and
directory). When I run the macro, the email gets sent to everyone, but
it
also keeps sending just the attachment to the last person in the
directory.
So, that person receives the correct email with the message and
attachment,
plus another email with just the attachment (but, no message). Any idea
of
why that would be happening?

I was having a problem earlier of the email going out with the
attachment,
but the "to" names did not match up to their respective "Dear *name*"
in
the
message. That is not happening anymore, and to tell you the truth, I've
run
so many tests that I don't know how I fixed it. (If any of that made
sense,
and you know why the source would not match up the names of the people
correctly, please please please let me know. That one had me baffled.)

Thanks for any suggestions on why the extra email would be going out
with
just the attachment to one of the recipients. If I should post this
question
to the Word group, please let me know.

Thanks, again! I thought I was done bugging you!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.

That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word VBE's
Tools-References option? There can be hundreds of objects in the
list -
e.g. on my system, that particular entry is about the 450th in the
list.

It would be checked by defaul tin Outlook itself, but it would not be
checked (and therefore near the top of the list ) by default in Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft
Outlook
12.0
Object Library" is checked. In Word, where the macro is run from,
there
is
no
option for "Microsoft Outlook 12.0 Object Library." There is a check
next
to
"Microsoft Office 12.0 Object Library" - this is also checked in OL.
Since
an
email merge from OL takes you to Word anyway, I **assumed** that is
where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly
into
the
VB
window, but the article didn't indicate if something had to be
modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it
(where
nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which includes
an
attachment - thanks to the very helpful articles you've provided.
However,
when I get to the part where I run the macro, I end up with a
dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button, it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me what
the
message
means, and how to fix it? If I can get this email merge with an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I don't
work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make use
of
it,
see
the article "What do I do with macros sent to me by other
newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Thanks Doug - I don't work with VB so I guess for me the
answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Is it possible to attach a file when doing an email
merge?


  #19   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default Email merge - attach file

Hi Tammy,

The following line of code:

MsgBox Source.Sections.Count & " messages have been sent."

should be

MsgBox Source.Sections.Count - 1 & " messages have been sent."

Thanks for pointing that out. I will have to get it changed as well.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Tammy" wrote in message
...
Hi Doug,

Thanks very much for the line of code! That fixed my problem.

The only other thing I saw was in the final count indicated in the dialog
box. For example, I sent two letters, but the dialog box indicated that
three
were sent. My sent folder only shows two sent, which is what I wanted.

Is there something else I should change in the code, or will this be the
"norm"?

Thanks, again for the GREAT article!! Peter has been awesome walking me
through a couple of other things, too. Really appreciate people like you
and
Peter! Thanks for the help!

"Doug Robbins - Word MVP" wrote:

I recently had that article updated and in doing so, an error crept into
the
code of the macro.

The line of code

For j = 1 To Source.Sections.Count

should be

For j = 1 To Source.Sections.Count - 1


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Tammy" wrote in message
...
Hi Peter,

I knew it was probably a guessing game at this point. Thanks for giving
me
some places to look.

My table is complete, with no extra characters or empty cells. The
merged
document has the correct number of letters (four, in this example)
after
merging to individual letters. However, there are a total of five
sections,
instead of four. Word has automatically added an additional return at
the
end
of the last letter, and the extra return appears in section five. Word
has
placed the extra return after a "continuous" section break in the last
letter. (All the other letters are separated with a "next page" section
break.)

I can't delete the extra return.

After noticing that, I returned to the merged emails from yesterday and
realized this did happen then, too. The last person received the
correct
email message and attachment, plus an additional email with just the
attachment.

Do you think this is a question I should post to the Word group? I'm
not
so
sure it has anything to do with Outlook, or the macro to run the email
with
attachment.

I really do appreciate the time you've taken with all of this. I also
checked both of your responses as "helpful" but haven't seen the green
check
mark yet. Thanks, again!

"Peter Jamieson" wrote:

I expect I'm guessing more than Doug would be at this point, but...
a. you should be able to look at the table that you create when you
do
your
catalog/directory merge.
- how many rows does it have?
- does the last row have non-blank values in both column 1 and
column
2?
b. you should also be able to save the document produced by the
second
mailmerge. If you click right at the end of the document
- how many sections does it have (you should be able to see int he
Word
status bar)

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Yesterday I had this working without a hitch, but today I am running
into
problems.

I have a data source that matches my directory exactly - same amount
of
records and they all have an email addresses (same people in the
source
and
directory). When I run the macro, the email gets sent to everyone,
but
it
also keeps sending just the attachment to the last person in the
directory.
So, that person receives the correct email with the message and
attachment,
plus another email with just the attachment (but, no message). Any
idea
of
why that would be happening?

I was having a problem earlier of the email going out with the
attachment,
but the "to" names did not match up to their respective "Dear
*name*"
in
the
message. That is not happening anymore, and to tell you the truth,
I've
run
so many tests that I don't know how I fixed it. (If any of that made
sense,
and you know why the source would not match up the names of the
people
correctly, please please please let me know. That one had me
baffled.)

Thanks for any suggestions on why the extra email would be going out
with
just the attachment to one of the recipients. If I should post this
question
to the Word group, please let me know.

Thanks, again! I thought I was done bugging you!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.

That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word
VBE's
Tools-References option? There can be hundreds of objects in the
list -
e.g. on my system, that particular entry is about the 450th in the
list.

It would be checked by defaul tin Outlook itself, but it would not
be
checked (and therefore near the top of the list ) by default in
Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft
Outlook
12.0
Object Library" is checked. In Word, where the macro is run from,
there
is
no
option for "Microsoft Outlook 12.0 Object Library." There is a
check
next
to
"Microsoft Office 12.0 Object Library" - this is also checked in
OL.
Since
an
email merge from OL takes you to Word anyway, I **assumed** that
is
where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly
into
the
VB
window, but the article didn't indicate if something had to be
modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it
(where
nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which
includes
an
attachment - thanks to the very helpful articles you've
provided.
However,
when I get to the part where I run the macro, I end up with a
dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button,
it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me
what
the
message
means, and how to fix it? If I can get this email merge with
an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I
don't
work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make
use
of
it,
see
the article "What do I do with macros sent to me by other
newsgroup
readers
to help me out?" at:

http://www.word.mvps.org/FAQs/Macros...eateAMacro.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Is not the macro written in visual basic?

"Doug Robbins - Word MVP" wrote:

I am not sure what you mean by VB.

However, I can assure you that if you follow the
instructions
precisely
(to
the letter), it will work.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Thanks Doug - I don't work with VB so I guess for me the
answer
is
that
I
would have to insert them to each individual email.

"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments"
at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail
yourself
of
my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in
message
...
Is it possible to attach a file when doing an email
merge?




  #20   Report Post  
Posted to microsoft.public.word.mailmerge.fields
tammy tammy is offline
external usenet poster
 
Posts: 107
Default Email merge - attach file

Works great! Thanks, again Doug! Take tomorrow off. haha

Really appreciated the help!

"Doug Robbins - Word MVP" wrote:

Hi Tammy,

The following line of code:

MsgBox Source.Sections.Count & " messages have been sent."

should be

MsgBox Source.Sections.Count - 1 & " messages have been sent."

Thanks for pointing that out. I will have to get it changed as well.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Tammy" wrote in message
...
Hi Doug,

Thanks very much for the line of code! That fixed my problem.

The only other thing I saw was in the final count indicated in the dialog
box. For example, I sent two letters, but the dialog box indicated that
three
were sent. My sent folder only shows two sent, which is what I wanted.

Is there something else I should change in the code, or will this be the
"norm"?

Thanks, again for the GREAT article!! Peter has been awesome walking me
through a couple of other things, too. Really appreciate people like you
and
Peter! Thanks for the help!

"Doug Robbins - Word MVP" wrote:

I recently had that article updated and in doing so, an error crept into
the
code of the macro.

The line of code

For j = 1 To Source.Sections.Count

should be

For j = 1 To Source.Sections.Count - 1


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Tammy" wrote in message
...
Hi Peter,

I knew it was probably a guessing game at this point. Thanks for giving
me
some places to look.

My table is complete, with no extra characters or empty cells. The
merged
document has the correct number of letters (four, in this example)
after
merging to individual letters. However, there are a total of five
sections,
instead of four. Word has automatically added an additional return at
the
end
of the last letter, and the extra return appears in section five. Word
has
placed the extra return after a "continuous" section break in the last
letter. (All the other letters are separated with a "next page" section
break.)

I can't delete the extra return.

After noticing that, I returned to the merged emails from yesterday and
realized this did happen then, too. The last person received the
correct
email message and attachment, plus an additional email with just the
attachment.

Do you think this is a question I should post to the Word group? I'm
not
so
sure it has anything to do with Outlook, or the macro to run the email
with
attachment.

I really do appreciate the time you've taken with all of this. I also
checked both of your responses as "helpful" but haven't seen the green
check
mark yet. Thanks, again!

"Peter Jamieson" wrote:

I expect I'm guessing more than Doug would be at this point, but...
a. you should be able to look at the table that you create when you
do
your
catalog/directory merge.
- how many rows does it have?
- does the last row have non-blank values in both column 1 and
column
2?
b. you should also be able to save the document produced by the
second
mailmerge. If you click right at the end of the document
- how many sections does it have (you should be able to see int he
Word
status bar)

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Yesterday I had this working without a hitch, but today I am running
into
problems.

I have a data source that matches my directory exactly - same amount
of
records and they all have an email addresses (same people in the
source
and
directory). When I run the macro, the email gets sent to everyone,
but
it
also keeps sending just the attachment to the last person in the
directory.
So, that person receives the correct email with the message and
attachment,
plus another email with just the attachment (but, no message). Any
idea
of
why that would be happening?

I was having a problem earlier of the email going out with the
attachment,
but the "to" names did not match up to their respective "Dear
*name*"
in
the
message. That is not happening anymore, and to tell you the truth,
I've
run
so many tests that I don't know how I fixed it. (If any of that made
sense,
and you know why the source would not match up the names of the
people
correctly, please please please let me know. That one had me
baffled.)

Thanks for any suggestions on why the extra email would be going out
with
just the attachment to one of the recipients. If I should post this
question
to the Word group, please let me know.

Thanks, again! I thought I was done bugging you!

"Peter Jamieson" wrote:

I **assumed** that is where the
macro had to be created.

That is the correct assumption in this case.

But I wonder if you have looked down the whole list in the Word
VBE's
Tools-References option? There can be hundreds of objects in the
list -
e.g. on my system, that particular entry is about the 450th in the
list.

It would be checked by defaul tin Outlook itself, but it would not
be
checked (and therefore near the top of the list ) by default in
Word.


--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Peter,

Thanks so much for taking the time to answer my post.

I checked two places for the reference - in Outlook, "Microsoft
Outlook
12.0
Object Library" is checked. In Word, where the macro is run from,
there
is
no
option for "Microsoft Outlook 12.0 Object Library." There is a
check
next
to
"Microsoft Office 12.0 Object Library" - this is also checked in
OL.
Since
an
email merge from OL takes you to Word anyway, I **assumed** that
is
where
the
macro had to be created.

Any other suggestions ? I copied and pasted the VB code directly
into
the
VB
window, but the article didn't indicate if something had to be
modifed.
Thanks, again!

"Peter Jamieson" wrote:

I'm not Doug, but you probably need to use the VB Editor's
Tools-References
option to locate "Microsoft Outlook nn.0 Library" and check it
(where
nn
depends on the version of Outlook you are using).

--
Peter Jamieson
http://tips.pjmsn.me.uk

"Tammy" wrote in message
...
Hi Doug,

I am trying to work through sending an email merge which
includes
an
attachment - thanks to the very helpful articles you've
provided.
However,
when I get to the part where I run the macro, I end up with a
dialog
box
that
says "Compile error: User-defined type not defined."

It then takes me to the VB window and highlights "Sub
emailmergewithattachments()" - if I click the continue button,
it
highlights
the Dim
"oOutlookApp As Outlook.Application"
line.

I apologize that I am unfamiliar with VB - can you tell me
what
the
message
means, and how to fix it? If I can get this email merge with
an
attachment
to
work, there will be many happy people at my office.

Really appreciate any suggestions! Thank you!

"Doug Robbins - Word MVP" wrote:

Sorry, yes it is. I guess I was half awake when I read "I
don't
work
with
VB" as "It doesn't work with VB"

However, all of the VB work has been done for you. To make
use
of
it,
see
the article "What do I do with macros sent to me by other
newsgroup
readers



  #21   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Mannie G Mannie G is offline
external usenet poster
 
Posts: 2
Default Email merge - attach file

Doug,

Thanks for the code for the email attachment problem, however if I use the
directory with Forename field mailmerge does not apply the correct
forename to the email address or sometimes outlook will substitute the email
address of someone with the same name from 'Contacts'. How can I
auomatically enter the forenames of the people I am sending the mailmerge
emails to?

Help would be appreciated
--
Thanks

Mannie G


"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?




  #22   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Doug Robbins - Word MVP Doug Robbins - Word MVP is offline
external usenet poster
 
Posts: 8,832
Default Email merge - attach file

I am not sure what you mean by "mailmerge does not apply the correct
forename to the email address"

What is the content of the Forename field?
--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP, originally posted via msnews.microsoft.com

"Mannie G" wrote in message
...
Doug,

Thanks for the code for the email attachment problem, however if I use the
directory with Forename field mailmerge does not apply the correct
forename to the email address or sometimes outlook will substitute the
email
address of someone with the same name from 'Contacts'. How can I
auomatically enter the forenames of the people I am sending the mailmerge
emails to?

Help would be appreciated
--
Thanks

Mannie G


"Doug Robbins - Word MVP" wrote:

See the article "Mail Merge to E-mail with Attachments" at

http://word.mvps.org/FAQs/MailMerge/...ttachments.htm


--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Mary Ann" wrote in message
...
Is it possible to attach a file when doing an email merge?




Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I attach a file & use voting buttons in an email merge? panamajackie Mailmerge 1 January 30th 07 04:38 AM
How do I attach a file to a merged email messages automatically? shopaholic Mailmerge 2 May 31st 06 06:44 AM
Is there a way to send merge email and to attach a file to the ema Anatpat Mailmerge 2 February 13th 06 04:37 AM
I want to attach a folder to an email not just 1 file? rsp1022 Microsoft Word Help 1 February 18th 05 05:45 PM
How to attach a PDF file to a Mail Merge Email from Word? RPMissions Mailmerge 1 January 16th 05 07:06 AM


All times are GMT +1. The time now is 12:50 AM.

Copyright ©2000 - 2023, Jelsoft Enterprises Ltd.
Copyright 2004-2023 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"