 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
AZ Guest
|
Posted: Wed Jun 25, 2003 2:51 pm Post subject: VBA to Delphi |
|
|
Hi,
What is the equivalent of:
Windows("Document2").Activate
in Delphi?
I tried with Windows.Item("Document2").Activate, where 'Document2' is of
type OleVariant but an exception is raising. I want to be able to switch
between documents (run time open) at run time.
regards
|
|
| Back to top |
|
 |
Dmitry Streblechenko Guest
|
Posted: Wed Jun 25, 2003 5:19 pm Post subject: Re: VBA to Delphi |
|
|
Did you try
Windows.Item['Document2'].Activate
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"AZ" <xtcsuk (AT) yahoo (DOT) co.uk> wrote
| Quote: | Hi,
What is the equivalent of:
Windows("Document2").Activate
in Delphi?
I tried with Windows.Item("Document2").Activate, where 'Document2' is of
type OleVariant but an exception is raising. I want to be able to switch
between documents (run time open) at run time.
regards
|
|
|
| Back to top |
|
 |
AZ Guest
|
Posted: Wed Jun 25, 2003 5:49 pm Post subject: Re: VBA to Delphi |
|
|
Yes, I did, it would come up with error something like 'object not in the
collection'.
regards
"Dmitry Streblechenko" <dmitry (AT) dimastr (DOT) com> wrote
| Quote: | Did you try
Windows.Item['Document2'].Activate
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"AZ" <xtcsuk (AT) yahoo (DOT) co.uk> wrote in message
news:3ef9b6ba (AT) newsgroups (DOT) borland.com...
Hi,
What is the equivalent of:
Windows("Document2").Activate
in Delphi?
I tried with Windows.Item("Document2").Activate, where 'Document2' is of
type OleVariant but an exception is raising. I want to be able to
switch
between documents (run time open) at run time.
regards
|
|
|
| Back to top |
|
 |
Dmitry Streblechenko Guest
|
Posted: Wed Jun 25, 2003 7:25 pm Post subject: Re: VBA to Delphi |
|
|
Can you pass an integer index (say, 1) instead of 'Document2'?
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"AZ" <xtcsuk (AT) yahoo (DOT) co.uk> wrote
| Quote: | Yes, I did, it would come up with error something like 'object not in the
collection'.
regards
"Dmitry Streblechenko" <dmitry (AT) dimastr (DOT) com> wrote in message
news:3ef9d9b9$1 (AT) newsgroups (DOT) borland.com...
Did you try
Windows.Item['Document2'].Activate
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"AZ" <xtcsuk (AT) yahoo (DOT) co.uk> wrote in message
news:3ef9b6ba (AT) newsgroups (DOT) borland.com...
Hi,
What is the equivalent of:
Windows("Document2").Activate
in Delphi?
I tried with Windows.Item("Document2").Activate, where 'Document2' is
of
type OleVariant but an exception is raising. I want to be able to
switch
between documents (run time open) at run time.
regards
|
|
|
| Back to top |
|
 |
AZ Guest
|
Posted: Thu Jun 26, 2003 7:07 am Post subject: Re: VBA to Delphi |
|
|
Yes, but still an error. I can see the way VBA does it by recording a macro
in Word, you can pass either the name of the document or the index.
regards
"Dmitry Streblechenko" <dmitry (AT) dimastr (DOT) com> wrote
| Quote: | Can you pass an integer index (say, 1) instead of 'Document2'?
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"AZ" <xtcsuk (AT) yahoo (DOT) co.uk> wrote in message
news:3ef9e082 (AT) newsgroups (DOT) borland.com...
Yes, I did, it would come up with error something like 'object not in
the
collection'.
regards
"Dmitry Streblechenko" <dmitry (AT) dimastr (DOT) com> wrote in message
news:3ef9d9b9$1 (AT) newsgroups (DOT) borland.com...
Did you try
Windows.Item['Document2'].Activate
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"AZ" <xtcsuk (AT) yahoo (DOT) co.uk> wrote in message
news:3ef9b6ba (AT) newsgroups (DOT) borland.com...
Hi,
What is the equivalent of:
Windows("Document2").Activate
in Delphi?
I tried with Windows.Item("Document2").Activate, where 'Document2'
is
of
type OleVariant but an exception is raising. I want to be able to
switch
between documents (run time open) at run time.
regards
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|