![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
Hi,
I am using Outlook Application ActiveWindow() API to get the topmost window of Outlook. It should return either Explorer or Inspector object. I have two Outlook windows 1. Outlook Application 2. NewMail Item inspector window NewMail inspector window is activated (as I am writing writing mail). Now if I am using OutlookSPY to get the ActiveWindow it returns the object of Explorer. It should return Inspector object of NewMailInspector window. I have tried this from C# program also. There also I found that ActiveWindow always returns Explorer objects. Any help will be appreciated. Atul Sureka |
Ads |
#2
|
|||
|
|||
![]()
It works here. Try this in the immediate window of the Outlook VBA project:
? Application.ActiveWindow.Caption When you have an item open and active. I haven't tried this using C#, but it works just fine in VBA code. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003 Reminder Manager, Extended Reminders, Attachment Options http://www.slovaktech.com/products.htm "AtulSureka" wrote in message ... Hi, I am using Outlook Application ActiveWindow() API to get the topmost window of Outlook. It should return either Explorer or Inspector object. I have two Outlook windows 1. Outlook Application 2. NewMail Item inspector window NewMail inspector window is activated (as I am writing writing mail). Now if I am using OutlookSPY to get the ActiveWindow it returns the object of Explorer. It should return Inspector object of NewMailInspector window. I have tried this from C# program also. There also I found that ActiveWindow always returns Explorer objects. Any help will be appreciated. Atul Sureka |
#3
|
|||
|
|||
![]()
Thanks for the reply.
But it is not working on my system. On my machine I have two Outlook windows - one is main Outlook explorer and other is NewMail Inspector. NewMail Inspector is active and it is over the Outlook Explorer window. With using Outlook SPY - I have clicked in CurrentItem in the NewMail Inspector window - Application - call ActiveWindow() function - It return the Outlook Explorer object not the NewMail Inspector window. I am not familiar with VBA so I have tested this using C# Outlook Addin. Can you verify this on your system with Outlook SPY. Atul Sureka "Ken Slovak - [MVP - Outlook]" wrote: It works here. Try this in the immediate window of the Outlook VBA project: ? Application.ActiveWindow.Caption When you have an item open and active. I haven't tried this using C#, but it works just fine in VBA code. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003 Reminder Manager, Extended Reminders, Attachment Options http://www.slovaktech.com/products.htm "AtulSureka" wrote in message ... Hi, I am using Outlook Application ActiveWindow() API to get the topmost window of Outlook. It should return either Explorer or Inspector object. I have two Outlook windows 1. Outlook Application 2. NewMail Item inspector window NewMail inspector window is activated (as I am writing writing mail). Now if I am using OutlookSPY to get the ActiveWindow it returns the object of Explorer. It should return Inspector object of NewMailInspector window. I have tried this from C# program also. There also I found that ActiveWindow always returns Explorer objects. Any help will be appreciated. Atul Sureka |
#4
|
|||
|
|||
![]()
If I open a new mail Inspector and select CurrentItem in OutlookSpy, then go
to the Script tab and enter the following script line: debug.print application.activewindow.caption and then click on Run I get the caption of the Inspector window. -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003 Reminder Manager, Extended Reminders, Attachment Options http://www.slovaktech.com/products.htm "AtulSureka" wrote in message ... Thanks for the reply. But it is not working on my system. On my machine I have two Outlook windows - one is main Outlook explorer and other is NewMail Inspector. NewMail Inspector is active and it is over the Outlook Explorer window. With using Outlook SPY - I have clicked in CurrentItem in the NewMail Inspector window - Application - call ActiveWindow() function - It return the Outlook Explorer object not the NewMail Inspector window. I am not familiar with VBA so I have tested this using C# Outlook Addin. Can you verify this on your system with Outlook SPY. Atul Sureka |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
How do I setup automatic return reciept for one person in Outlook | Sam Echols | Outlook - General Queries | 3 | July 22nd 06 05:13 PM |
Email hyperlinks open Windows Explorer, not Internet Explorer | M Skabialka | Outlook - General Queries | 2 | July 7th 06 09:39 PM |
Explorer.exe -Application Error | Dirving | Outlook - Installation | 1 | July 5th 06 05:36 PM |
Convert double value return by Outlook api to CTime | amit deshpande | Outlook and VBA | 2 | June 27th 06 05:56 AM |
Outlook return address issues | Joejean | Outlook - Installation | 0 | June 24th 06 07:30 PM |