Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 08-24-2021, 10:11 PM
gmayor's Avatar
gmayor gmayor is offline Merging of colums from two different docs & create a new doc Windows 10 Merging of colums from two different docs & create a new doc Office 2019
Expert
 
Join Date: Aug 2014
Posts: 4,144
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 ofgmayor has much to be proud of
Default

Change the line
Code:
If Not oTable1.Rows.Count = oTable2.Rows.Count Then GoTo lbl_Exit
to
Code:
If Not oTable1.Rows.Count = oTable2.Rows.Count Then
    MsgBox "The tables do not have the same number of rows", vbCritical
    GoTo lbl_Exit
End If
Directly after the line
Code:
Set oSource = Documents.Open(sSource)
add the line
Code:
 oSource.AcceptAllRevisions

__________________
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
Reply

Tags
merging of colums



Similar Threads
Thread Thread Starter Forum Replies Last Post
Merging of colums from two different docs & create a new doc Merging Word docs / PDFs while keeping external links Daedalus Word 1 05-11-2015 07:37 AM
Merging of colums from two different docs & create a new doc Merging Various .docs Via Q&A Wants_It_Simple Word 1 06-30-2014 10:26 PM
Merging of colums from two different docs & create a new doc How to create shorter docs from large base template? Preloader Word 13 10-19-2013 09:39 PM
Fields/Colums in folders cilimpuli Outlook 1 03-10-2013 12:20 PM
Merging of colums from two different docs & create a new doc Is it possible to create 'balloon' text in docs bubbleboi Word 3 11-13-2009 01:19 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 01:35 PM.


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