Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Automation error -2147417851

75 views
Skip to first unread message

D.Stone

unread,
Jun 1, 2000, 3:00:00 AM6/1/00
to
I am developing an Access application which uses Automation to mail-merge
database data (names & addresses) with Word template documents. This part
of the application was working fine under Acc97 -- and then it emerged that
the user's target machine was running Office 2000!

I installed Office 2000 on my machine in a separate directory, leaving
Office 97 where it was. The database application was converted to Access
2000 format, and object library references pointed at the 9.0 versions.

When the application is started in Access 2000 and runs through the
mail-merge code now, it starts Word, but the first significant automation
operation after that ( the code actually says:
oWord.Documents.Add (Template)
where oWord is declared as Word.Application, and Template is a string
containing the template document's full path + file-name) gives an error:
"-2147417851: automation error
The server threw an exception"
The puzzling thing is that the CreateObject call:
Set oWord = CreateObject("Word.Application")
starts Word97 rather than 2000.

To the best of my knowledge, the application runs error-free on the user's
(Office 2000 only) installation.

The obvious inference is that, in a mixed environment, some inconsistency
(registry entry?) arises that the OLE automation library can't cope with.

Anyone else met this or something similar?

Dave


Arvin Meyer

unread,
Jun 1, 2000, 3:00:00 AM6/1/00
to
Yes, Word, like Access, uses a default registration to open the currently
registered application. Like Access, the last version of Word used, is the
last version registered. If opening Word 2000 by itself first, it "should"
register. But then your Access97 version automations with Word won't work
properly :(

My solution is to use plug-in hard drives. At less than $200 for both rack
mount and 20 GB drive, you can keep multiple O/S_application solutions. Much
cheaper than separate machines.
---
Arvin Meyer

D.Stone wrote in message <8h5kkk$gkv$1...@scotsman.ed.ac.uk>...

0 new messages