Re: Office 9 references automatically updated to Office 11.

Tech-Archive recommends: Fix windows errors by optimizing your registry



I have found (in my limited circumstances) that the Word9 object library
(.olb) works fine for later Word if the msword9.olb is distributed (which
technically is illegal). I can't say if it applies to Office references,
though they are "often" backwards compatible.

But this is an empirical approach. If it doesn't work, I have no-one to blame
but myself for mixing versions or incompatible references.

Then I discovered "late-binding"! Problem solved! (though theoretically
slower) A very poor reflection on the principle of common "DLL's", but it's a
necessary approach to avoid all the DLL or Reference problems. The simple fact
is, the principle of common DLL's was a good one, but MS stuffed it up so bad
that it mostly doesn't work. One would have thought that, if one uses "no
later features" it should be all compatible. This is demonstrably not the case
(even changing the NAME of a reference 9->10 causes incompatibility).

Users should not be able to click "debug". That's a terrible thing to allow-I
mean whatever would they do with that?

Two versions is one approach, but much more maintenance than (say)
late-binding if that's the only issue.

> Does anyone have any other, better ideas?
Well, it should be capable of running under the /Runtime switch if not full
Runtime, which disallows such things as "debug".

Chris

PS Conversion from references to late-binding involved, for me, nothing more
than a few object definition changes and a few constants being inserted. In
fact, I can easily change back to early-binding for development (to get the
intellisense help), to my heart's content.

"Matt" <Matt@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
> Hi, I can't seem to find any info on the problem I'm having, so if anyone
> could help that would be great.
>
> I've just taken over a rather large Access database developed in Access
> 2000, which uses automation to control other Office apps and therefore has
> the appropriate (version 9) references set. Recently half the users have
> been upgraded to Access 2003, although the database remains in 2000 format.
>
> The problem is that when an error occurs (as does happen, alas) for a user
> running 2003, and the end-user clicks "Debug" (as inquisitive scientists
> will), the VBA editor on their machine seems to automatically convert the
> various Office 9 references to the Office 11 equivalents. This means the
> next time a 2000 user tries to open the database, the v11 references can't
be
> found and the whole thing falls over.
>
> Does anyone have any suggestions for a quick solution to this problem?
>
> My thoughts so far:
> 1. Late-binding - seems the best solution, but given the amount of code in
> this database, would take quite a long time to implement.
>
> 2. Don't let the users click "Debug" - the error checking is definitely
> deficient at the moment, but again the sheer number of functions to be
> updated means that this would take a while to implement. Is there a way of
> setting a sort of "global error handler"? Ideally I'd want any un-handled
> error, anywhere in the code, to simply display some error information with
an
> "OK" button.
>
> 3. Two versions. This seems like it's going to be the only (quick) solution
> - by having a 2000 and a 2003 version.
>
> Does anyone have any other, better ideas?
>
> Many thanks in advance!
> -matt


.


Quantcast