Re: GetObject-question
From: Tom Ogilvy (twogilvy_at_msn.com)
Date: 06/10/04
- Next message: Frank Kabel: "Re: Saveas with name of another file"
- Previous message: Tom Ogilvy: "Re: Personal.xls Macros?"
- In reply to: Tom: "GetObject-question"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 10 Jun 2004 12:17:49 -0400
Use the shell command and point it to the proper executable, then perhaps
you can get a reference to it using the caption. GetObject will always use
the last registered version - so an alternative would be to reregister xl97,
but that probably isn't advisable.
--
Regards,
Tom Ogilvy
"Tom" <tstruebi@gmx.net> wrote in message
news:O07tLOwTEHA.3332@tk2msftngp13.phx.gbl...
> Hi
>
> I have installed four Excel versions on my pc (97, 2000, XP & 2003). I
have
> written an external vba script, that opens an Excel instance. Now I'd like
> to test my script with 97, but the script always opens Excel 2003. I'm
using
> the following comand:
>
> On Error Resume Next
> Set oXL = GetObject(, "Excel.Application.8")
>
> If Err.Number <> 0 Then
> Set oXL = CreateObject("Excel.Application.8")
> End If
>
> On Error GoTo 0
> oXL.Visible = True
>
> Any ideas how to open Excel 97? Many thanks in advance!
>
> Tom
>
>
>
- Next message: Frank Kabel: "Re: Saveas with name of another file"
- Previous message: Tom Ogilvy: "Re: Personal.xls Macros?"
- In reply to: Tom: "GetObject-question"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|