Solved

How to Paste a Table with Word Automation

Posted on 2009-05-08
3
279 Views
Last Modified: 2013-11-10
I am doing Word (2003) automation. In my app, I have two documents open. Doc1 contains this string: **SOURCEINFO**.

Doc2 is a document that contains formatted text and multiple tables.

I want to replace the string **SOURCEINFO** in Doc1 with the entirety of Doc2.

Can you show me the best way that preserves all the formatting in Doc2?
0
Comment
Question by:AIBMass
  • 2
3 Comments
 
LVL 37

Expert Comment

by:Joanne M. Orzech
ID: 24368502
I'm not quite sure I understand your question completely - what type of automation are you talking about?  VB?  

Or you could always use the INCLUDETEXT field code....
http://daiya.mvps.org/includetext.htm
0
 

Author Comment

by:AIBMass
ID: 24381123
I am talking about Office automation in VB.Net

Dim Word as application, etc.....


0
 

Accepted Solution

by:
AIBMass earned 0 total points
ID: 24451027
Selection.PasteAndFormat(0)
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
The viewer will learn how to make their project stand out over others by learning how to change colors and shapes, add spaces, change directions, and add bullets to their charts.
Learn how to create and modify your own paragraph styles in Microsoft Word. This can be helpful when wanting to make consistently referenced styles throughout a document or template.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now