PDA

View Full Version : Office automation fine 2007 and not sometimes 2010



Movian
10-01-2010, 08:35 AM
Ok i have a system that produces entire word documents through office automation.

I have been working on this for a few years and you guys have helped me in some of my tougher moments on this same system.
The system is designed to produce these documents through late binding office automation.

The system works fine for office 2003 and 2007 and MOST of the time it works fine for 2010... HOWEVER

in some instances when the users have 2010 installed the system will not be able to produce the document claiming that it they do not have a valid license to use this function in a design environment or something similar...

For the moment i have been downloading an office 2007 trial which then resolves the issue merely with its presence but allows the user to produce the reports in 2010.

However this is VERY un proffesional from our clients view point and i would like to figure out why 2010 is having this issue in the first place....

here are the applicable lines of code for creating the document ( with some other stuff removed as its not relevant)

Set WordApp = CreateObject("Word.Application")
fso.CopyFile temploc & repname & ".doc", fol & "\" & "Rep-" & Forms("frmMain").ReportDate & "_" & repname & Location & ".doc"
WordApp.Documents.Open fol & "\" & "Rep-" & Forms("frmMain").ReportDate & "_" & repname & Location & ".doc"


the system will loop through some bookmarks then make the word app visible.

Any help apriciated

HiTechCoach
10-01-2010, 10:30 PM
I have Office 2010 installed. I will see what I can figure out.

How can I try to duplicate the issue?

Will you post a sample database that is generating the error? If you will, I will definitely give it a test.

Movian
10-04-2010, 04:34 AM
The best way to test it...

If you have virtual machine i have managed to duplicate it by installing office xp sp3, and then installing office 2010 home and business edition.

i will see if i can create an example DB that creates the same problem. I would not be able to post up the production db.

I appreciate the Help and will try and get an example DB up ASAP

Movian
10-04-2010, 05:08 AM
Accidental double post. Please delete