View Single Post
  #6   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Paul M Paul M is offline
external usenet poster
 
Posts: 1
Default Compile Error: User-defined type not defined

When I try to follow the instructions for enabling email merging with an
attachment, I get "Compile Error: User-defined type not defined" after trying
to run the macro. Can anyone help? I am using Outlook 2003, Word 2003 (Office
2003) on a WinXP machine.

Here's what I did, per the instructions at
http://word.mvps.org/FAQs/MailMerge/...ntsContent.htm

- I downloaded and executed the Express ClickYes utility for Outlook.
- I open both Outlook and Word 2003
- In Word, I created a Directory file per the instructions, saved and closed
it.
- In Word, I created and saved the macro from the above website and called
it "Mail_Merge_With_Attachment". I saved and closed out of Visual Basic (or
whatever window the Create Macro feature in Word opens.
- I then created a mail merge document, selected the data to merge (an Excel
file with company names, first names, etc).
- I completed the merge, going through the last step and actually merging
(that is, I select the "Merge - Electronic Mail" option.
- I try to run the macro while in Word and get the Compile error noted above.

Any help is appreciated! - Paul M.

"JH-LKY" wrote:

The magic is almost working for me. I have read multiple posts, finally
muddled through creating a macro and I can send to my list from Outlook, it
looks like a one-to-one email, and there is a PDF attachment. Except,
somewhere I've missed how to make my message show up. I have created a new
Word doc, merged it, and then executed the macro - but I still get an empty
message with the attachment. What am I doing wrong??