Word-Excel Mail merge problem

Status
This thread has been Locked and is not open to further replies. Please start a New Thread if you're having a similar issue. View our Welcome Guide to learn how to use this site.

caraneta

Thread Starter
Joined
Nov 4, 2004
Messages
14
We have Word 2002 and excel 2002 applications we are trying to merge an excel file to Word and we are having problems getting getting the format correct. we have 4 decimal places on excel file, when we merge it to word it changes the format and puts a lot of zeroes on the file.
I also got this window message when we open the word file "Opening this Doc will run the following SQL on Select * From 'Sheet1$' Data from your...Base wil be placed in the Document. Do you wan to continue?"
We always click yes.
I looked at MS KB online the only thing I see is 97,98 older versions of Word and Excel. Has anybody experienced this problem already?
Please help. Thank you
 

caraneta

Thread Starter
Joined
Nov 4, 2004
Messages
14
Thank you Andy. We found another solution or more like a workaround published at Microsoft help and support Q304387. This workaround works BUT our word file is big and it will take a long time to edit each field. We can do it but there is a deadline.
I noticed on our Excel file there are Green Triangle/ and exclamation when the mouse pointer is on top of it, beside almost all the columns where the numbers are, do you know how to get that out of there? somehow it is connected to the Merge problem.
A box pops up saying "This Cell contains a formula and is not locked to help protect it from being changed inadvertently." When I click the down arrow, one of the choices is unprotect. I assume it is protected already.
Thank you for your help.
-- Cesar
 
Joined
Aug 30, 2003
Messages
2,702
>> Green Triangle/ and exclamation

This is a 2002 or 2003 thing, I think. I've only ever seen 2K2 for about 5 mins. It's possibly called "Smart Tags" (?). Is there a rightclick option to "Ignore This Error/Alert"?
 

caraneta

Thread Starter
Joined
Nov 4, 2004
Messages
14
Thank you for the tag problem, my co-worker got it out.
Our big problem is to fix the problem with Currency field not showing the correct format when merged from excel to word. How do we retain the formatting when we merge the document.
I have read at Q304387 symptoms That...When MS Word uses OLEDB in Excel Data Source The merge results for currency fields are incorrect.
Do I have to create a macro for it to use DDE. Is this the only solution?
Please help.
Thank you.
 
Joined
Aug 30, 2003
Messages
2,702
I bolted it together in a VBA module, and ended up with:

Sub DoMerge()
Dim oMM As Word.MailMerge
Set oMM = Documents.Add.MailMerge
oMM.MainDocumentType = wdFormLetters

'Force Word 2002 to emulate Word 2000 behavior
'(use DDE for the data access).
oMM.OpenDataSource _
Name:="c:\program files\microsoft office\office10\samples\northwind.mdb", _
Connection:="TABLE Customers", _
SubType:=wdMergeSubTypeWord2000

oMM.EditMainDocument
oMM.Fields.Add Range:=Selection.Range, Name:="CompanyName"
oMM.Destination = wdSendToNewDocument
oMM.Execute
ActiveWindow.View.Type = wdNormalView
End Sub

From what it says, you'd just need to amend the path to northwind.mdb, which you find by doing a file search.
 
Status
This thread has been Locked and is not open to further replies. Please start a New Thread if you're having a similar issue. View our Welcome Guide to learn how to use this site.

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 807,865 other people just like you!

Latest posts

Members online

Top