ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   How do I isolate my Excel server (automation) from other Excel instances? (https://www.excelbanter.com/excel-discussion-misc-queries/2367-how-do-i-isolate-my-excel-server-automation-other-excel-instances.html)

Joseph Geretz

How do I isolate my Excel server (automation) from other Excel instances?
 
Our application uses Excel as a server via the Excel COM interface
(automation). However, I'm finding that when the user opens other Excel
documents, these documents all share the same Excel window. If the user then
hits X to exit their document (this is the normal user approach) this shuts
down Excel altogether and my server is gone!

Also, our application streamlines the Excel window by removing all toolbars.
I'm finding that now when the user opens their own documents, their favorite
toolbars are gone. Again, it's the same basic issue. How do I isolate our
own Excel server from other instances of Excel in the user's environment?

Thanks for your help!

- Joe Geretz -

P.S. How come there's no excel.vba group like there is for Word?



Frank Kabel

Hi
only for your last question:
excel.programming

Though most regulars also read this .misc NG anyway

--
Regards
Frank Kabel
Frankfurt, Germany

Joseph Geretz wrote:
Our application uses Excel as a server via the Excel COM interface
(automation). However, I'm finding that when the user opens other
Excel documents, these documents all share the same Excel window. If
the user then hits X to exit their document (this is the normal user
approach) this shuts down Excel altogether and my server is gone!

Also, our application streamlines the Excel window by removing all
toolbars. I'm finding that now when the user opens their own
documents, their favorite toolbars are gone. Again, it's the same
basic issue. How do I isolate our own Excel server from other
instances of Excel in the user's environment?
Thanks for your help!

- Joe Geretz -

P.S. How come there's no excel.vba group like there is for Word?




Stephen Bullen

Hi Joseph,

Our application uses Excel as a server via the Excel COM interface
(automation). However, I'm finding that when the user opens other Excel
documents, these documents all share the same Excel window. If the user then
hits X to exit their document (this is the normal user approach) this shuts
down Excel altogether and my server is gone!

Also, our application streamlines the Excel window by removing all toolbars.
I'm finding that now when the user opens their own documents, their favorite
toolbars are gone. Again, it's the same basic issue. How do I isolate our
own Excel server from other instances of Excel in the user's environment?

Thanks for your help!


To fix the underlying problem, you can set
Application.IgnoreRemoteRequests=True to make Windows start a new instance of
Excel when the user double-clicks an xls. You might also need/want to set
Application.Interactive=False. There's still the chance of someone getting your
instance of Excel if they double-click a workbook that's embedded in a Word
document (for example), which you might be able to avoid by starting *two*
instances of Excel (untested) - one for you to use, one to accept the COM
requests.

P.S. How come there's no excel.vba group like there is for Word?


Public.Excel.Programming fulfills that purpose for Excel.

Regards

Stephen Bullen
Microsoft MVP - Excel
www.oaltd.co.uk



Joseph Geretz

Thanks guys!

excel.programming - I missed that one. See you there in the near future, I'm
sure!

- Joe Geretz -

"Stephen Bullen" wrote in message
...
Hi Joseph,

Our application uses Excel as a server via the Excel COM interface
(automation). However, I'm finding that when the user opens other Excel
documents, these documents all share the same Excel window. If the user
then
hits X to exit their document (this is the normal user approach) this
shuts
down Excel altogether and my server is gone!

Also, our application streamlines the Excel window by removing all
toolbars.
I'm finding that now when the user opens their own documents, their
favorite
toolbars are gone. Again, it's the same basic issue. How do I isolate our
own Excel server from other instances of Excel in the user's environment?

Thanks for your help!


To fix the underlying problem, you can set
Application.IgnoreRemoteRequests=True to make Windows start a new instance
of
Excel when the user double-clicks an xls. You might also need/want to set
Application.Interactive=False. There's still the chance of someone getting
your
instance of Excel if they double-click a workbook that's embedded in a
Word
document (for example), which you might be able to avoid by starting *two*
instances of Excel (untested) - one for you to use, one to accept the COM
requests.

P.S. How come there's no excel.vba group like there is for Word?


Public.Excel.Programming fulfills that purpose for Excel.

Regards

Stephen Bullen
Microsoft MVP - Excel
www.oaltd.co.uk






i've got a solution for you

get rid of excel and start using Access.

better yet, use Access Data Projects-- store the data in SQL Server; and
then you won't have to worry about Excel automation; since you can get to
the real data using real tools




"Joseph Geretz" wrote in message
...
Our application uses Excel as a server via the Excel COM interface
(automation). However, I'm finding that when the user opens other Excel
documents, these documents all share the same Excel window. If the user

then
hits X to exit their document (this is the normal user approach) this

shuts
down Excel altogether and my server is gone!

Also, our application streamlines the Excel window by removing all

toolbars.
I'm finding that now when the user opens their own documents, their

favorite
toolbars are gone. Again, it's the same basic issue. How do I isolate our
own Excel server from other instances of Excel in the user's environment?

Thanks for your help!

- Joe Geretz -

P.S. How come there's no excel.vba group like there is for Word?





Mrjtwill

Stephen.. These two VBA commands have made a world of difference in my automation processes.

THANKS!!!


Application.IgnoreRemoteRequests=True
Application.Interactive=False

line codes from Stephen Bullen; Microsoft MVP - Excel


All times are GMT +1. The time now is 09:11 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com