Ask a Question

Vb Script Getobject method is not binding to an already open Outlook application

krishnapuli
Occasional Contributor

Vb Script Getobject method is not binding to an already open Outlook application

Hello Every One,

 

My requirement is to open outlook with Run as Admin option.After That i am trying to bind outlook with GetObject vb script method.But its not working on outlook though its perfectly binding with excel, word etc.

 

Any help in this regard.

2 REPLIES 2
AlexKaras
Champion Level 3

Hi,

 

Not sure, but considering that Outlook is a part of Office, this might appear to be of some help: https://smartbear-cc.force.com/portal/KbArticleViewer?name=Get-COM-reference-for-a-running-Excel-ins...

Regards,
  /Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================
krishnapuli
Occasional Contributor

Hi,

 

I have red the provided article and came to know that getobject function does not bind to the existing excel application.

 

I don't know the exact internals of how COM works but Getobject can get the existing excel reference.

 

Following steps works in VB script.

Set Obj=CreateObject("Excel.Application") will give  new excel instance.

Set Obj=GetObject(,"Excel.Application") will give existing excel instance.I.e Open excel application and run this statement.This statement binds to the opened excel application.

 

 

cancel
Showing results for 
Search instead for 
Did you mean: