Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Is it possible from VBA to run excel as administrator?
Is it possible from VBA to run excel as administrator so that VBA routines that create an instance of Outlook or Word will run as per normal.
|
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Is it possible from VBA to run excel as administrator?
Is it possible from VBA to run excel as administrator so that VBA routines
that create an instance of Outlook or Word will run as per normal. Please explain what you mean by "run as per normal". (What abnormal behaviour are you getting?) -- Garry Free usenet access at http://www.eternal-september.org Classic VB Users Regroup! comp.lang.basic.visual.misc microsoft.public.vb.general.discussion |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Is it possible from VBA to run excel as administrator?
On Thursday, December 21, 2017 at 3:42:30 PM UTC+11, GS wrote:
Is it possible from VBA to run excel as administrator so that VBA routines that create an instance of Outlook or Word will run as per normal. Please explain what you mean by "run as per normal". (What abnormal behaviour are you getting?) -- Garry Free usenet access at http://www.eternal-september.org Classic VB Users Regroup! comp.lang.basic.visual.misc microsoft.public.vb.general.discussion If Excel is not running as an administrator the vba routine that creates the object (CreateObject("Outlook.Application")) doesn't have permission to create an instance of Outlook (or Word). It works okay on my computer as I have excel set to run as administrator, but it doesn't work on other computers. I can't go an change the settings on all the other computers. |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Is it possible from VBA to run excel as administrator?
On Thursday, December 21, 2017 at 3:42:30 PM UTC+11, GS wrote:
Is it possible from VBA to run excel as administrator so that VBA routines that create an instance of Outlook or Word will run as per normal. Please explain what you mean by "run as per normal". (What abnormal behaviour are you getting?) -- Garry Free usenet access at http://www.eternal-september.org Classic VB Users Regroup! comp.lang.basic.visual.misc microsoft.public.vb.general.discussion If Excel is not running as an administrator the vba routine that creates the object (CreateObject("Outlook.Application")) doesn't have permission to create an instance of Outlook (or Word). It works okay on my computer as I have excel set to run as administrator, but it doesn't work on other computers. I can't go an change the settings on all the other computers. Ulrich makes a good point! Otherwise you can create more than 1 instance of Outlook so the practice is to check 1st if it's already running using: Dim appOL As Object, appWD As Object Set appOL = GetObject("Outlook.Application") If appOL Is Nothing Then Set appOL = CreateObject("Outlook.Application") Word on the other hand IS a multi-instance app same as Excel is. Note also that automated instances are not visible until you set their Visible property = True. Also, users won't have control until you set the UserControl property = True. As far as permissions go.., if a user has permission to use MS Office then automating its counterparts is allowed. -- Garry Free usenet access at http://www.eternal-september.org Classic VB Users Regroup! comp.lang.basic.visual.misc microsoft.public.vb.general.discussion |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How do I tell Excel that I am the administrator? | Excel Discussion (Misc queries) | |||
How administrator can delete temporary excel file generated on se | Excel Discussion (Misc queries) | |||
Excel macro works only for administrator | Excel Discussion (Misc queries) | |||
Can you create an administrator for an excel file that is not sub. | Excel Worksheet Functions |