Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 11-19-2018, 04:25 AM
blanka blanka is offline problem with merge excel file into word Windows 7 64bit problem with merge excel file into word Office 97-2003
Novice
problem with merge excel file into word
 
Join Date: Nov 2018
Posts: 4
blanka is on a distinguished road
Default problem with merge excel file into word

Hi everyone, I'm sorry if my english is not good, I'm from Italy and I've got a problem with merge between excel and word..
I've got an excel sheet automatically generated by the management program I use at work..
It's composed by 2 columns:

orcodart (the name of the every item of the order)

datalis (the date when I entered the price) if there is still no price in place of the date there is this code ( - -)

when I merge it in Word many times I've got this issue:
in place of "- -" when there is no date Word generate "12:00:00 AM" but i need to have "- -"
sometimes it works and generate "- -" but in this case it doesn't..

I attach the files

can you help me?
thanks bye
Attached Files
File Type: xls prova.XLS (13.5 KB, 12 views)
File Type: doc PROVA.doc (20.0 KB, 13 views)
Reply With Quote
  #2  
Old 11-19-2018, 07:13 AM
gmayor's Avatar
gmayor gmayor is offline problem with merge excel file into word Windows 10 problem with merge excel file into word Office 2016
Expert
 
Join Date: Aug 2014
Posts: 4,106
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Change the field construction to

{ IF { MERGEFIELD "datalis" } = "12:*" "- -" "{ MERGEFIELD "datalis" }" }
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
  #3  
Old 11-19-2018, 08:58 AM
blanka blanka is offline problem with merge excel file into word Windows 7 64bit problem with merge excel file into word Office 97-2003
Novice
problem with merge excel file into word
 
Join Date: Nov 2018
Posts: 4
blanka is on a distinguished road
Default

Quote:
Originally Posted by gmayor View Post
Change the field construction to

{ IF { MERGEFIELD "datalis" } = "12:*" "- -" "{ MERGEFIELD "datalis" }" }
Thank you very much Gmayor It seems to be the right solution!!!
I can't understand what is that text (12:00:00AM) gererated automatically.. (sometimes, not ever..)
but this fix the problem and it's the most important thing

Byeeee
Reply With Quote
  #4  
Old 11-19-2018, 12:44 PM
Charles Kenyon Charles Kenyon is offline problem with merge excel file into word Windows 10 problem with merge excel file into word Office 2016
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,140
Charles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant future
Default

Quote:
Originally Posted by blanka View Post
Thank you very much Gmayor It seems to be the right solution!!!
I can't understand what is that text (12:00:00AM) gererated automatically.. (sometimes, not ever..)
but this fix the problem and it's the most important thing

Byeeee

This is because the actual data in Excel is the number 0 which when formatted as time give you midnight. Word, in doing a merge, ignores the formatting that is used in Excel.
Reply With Quote
  #5  
Old 11-20-2018, 03:41 AM
blanka blanka is offline problem with merge excel file into word Windows 7 64bit problem with merge excel file into word Office 97-2003
Novice
problem with merge excel file into word
 
Join Date: Nov 2018
Posts: 4
blanka is on a distinguished road
Default

just another question if is possible
If I select "Confirm conversion at Open" from the Word Options and choosing again the source file excel it give me the possibility to select DDE.. In this way is possible to keep the same format of the Excel cells.. and it asks no format strings.. But everytime I open again the word file i have to select everytime the file Excel..
Is there a way to save the Word file including the Excel file inside?
thanks a lot
bye
Reply With Quote
  #6  
Old 11-20-2018, 01:40 PM
macropod's Avatar
macropod macropod is offline problem with merge excel file into word Windows 7 64bit problem with merge excel file into word Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,963
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Your underlying problem is that your 'datalis' field contains two data types. Approaches you might take to resolve it are discussed under Mailmerge Data Format Problems in the Mailmerge Tips & Tricks 'Sticky' thread at the top of this forum: https://www.msofficeforums.com/mail-...ps-tricks.html

DDE is old technology that was superseded by OLE DB over 15 years ago. When using DDE, you will always need the "Confirm conversion at Open" option.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #7  
Old 11-20-2018, 03:05 PM
blanka blanka is offline problem with merge excel file into word Windows 7 64bit problem with merge excel file into word Office 97-2003
Novice
problem with merge excel file into word
 
Join Date: Nov 2018
Posts: 4
blanka is on a distinguished road
Default

Quote:
Originally Posted by macropod View Post
Your underlying problem is that your 'datalis' field contains two data types. Approaches you might take to resolve it are discussed under Mailmerge Data Format Problems in the Mailmerge Tips & Tricks 'Sticky' thread at the top of this forum: https://www.msofficeforums.com/mail-...ps-tricks.html

DDE is old technology that was superseded by OLE DB over 15 years ago. When using DDE, you will always need the "Confirm conversion at Open" option.
My only question about DDE it was: is possible to save the excel file DDE as database inside the word file? Reading on the web I've not found any solutions about it..

For the formatting of my OLEDB file Excel Gmayor has already solved my issue..
Reply With Quote
  #8  
Old 11-20-2018, 05:26 PM
macropod's Avatar
macropod macropod is offline problem with merge excel file into word Windows 7 64bit problem with merge excel file into word Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,963
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Quote:
Originally Posted by blanka View Post
My only question about DDE it was: is possible to save the excel file DDE as database inside the word file? Reading on the web I've not found any solutions about it..
No. It is not possible to use content in a mailmerge main document as the datasource.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel to word Mail Merge problem mark_kofi Mail Merge 4 07-17-2018 03:49 PM
problem with merge excel file into word Merge one Excel file into multiple Word Documents Rushpac Mail Merge 2 01-27-2017 02:49 PM
Problem with saving Word file that is connected to Excel files that uses Powerpivot tables, charts Paul-NYS Office 2 08-24-2016 06:00 AM
A serious problem in integrating text file with an Excel file? mradmin Excel 12 10-25-2013 07:43 AM
Problem to view an Excel spreadsheet in Word file. d-force Word 2 08-28-2012 10:13 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 08:26 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft