Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Newly generated doc has different text than original

Status
Not open for further replies.

pmcdaniel

Programmer
Feb 9, 2007
127
US
I got a document which I use VBA from a Visual Basic 6 program to generate another document. The newly generated document has different colored fonts with underlines(some pink, some blue, some red) in some paragraphs but not others. Sometimes it's just a word. It is not like this in the original. The original does not have Track Changes on and I can't for the life of me figure how this has happened. We are using Word 2000.

Any help would be greatly appreciated!
 
Hi pmcdaniel,

Is it VBA or VB6?

Aside from that, the first thing you should check is that the styles used in both documents are defined exactly the same way. If they're not, this could affect the appearance of the new document.

Cheers

[MS MVP - Word]
 
Thanks for the reply, macropod.

We're running a VB 6 app. using the Word object with some bookmarks and docvariables. The Styles gets kinda funky because I find myself changing Styles on the master even though they show okay on it just so it comes out okay on the generated document. But doing this doesn't fix the current problem.

I've changed the Styles....or confirmed the style was what it should be on the master and it appears okay. Maybe I'm doing something wrong with Styles because it sure seems complicated sometimes.
 
I am trying to understand this.

If you are using a template - and I am assuming you are, since you use the word "generate" - the the cloned document from the template WILL have the format of the template.

If you are not using a template...I suggest you do.

Perhaps if you clarified "generated".

Gerry
My paintings and sculpture
 
I had the Highlight changes on screen and Highlight changes in printed document on! I'm still learning this....bought a book and read on it. Will probably put something in the VBA code to turn them off.

Thanks for your help!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top