Solved

Blocking the use of Excel

Posted on 1998-11-11
2
133 Views
Last Modified: 2010-04-30
My application uses CreateObject("Excel.Application") to create an Excel object with is then used to write data to a number of workbooks.  The problem is when someone double clicks on a .XLS workbook it is opened in my copy of excel.  I don't want this to happen.  My currect solution involves my application determining if there are more workbooks open than it expects and if there are the unwanted workbook is opened in its own copy.  This works for most cases, but if the user attempts to open the same workbook twice My copy of excel displays a dialog (as two copies of the workbook are open) forcing my copy to be visable.  Any ideas anybody.  Thanks.
0
Comment
Question by:wiffen
2 Comments
 
LVL 1

Accepted Solution

by:
pmteixeira earned 70 total points
Comment Utility
Hi wiffen,

supposing you have:

   Dim e As Excel.Application

   Sub xxx()
      Set e = CreateObject("Excel.Application")
                      ' why don't you use Set e = new Excel.Application ????

                     ' try adding this line
      e.IgnoreRemoteRequests = False
End Sub


Hope this helps,

PMT
0
 

Author Comment

by:wiffen
Comment Utility
Thank you ever so much that seems to work perfectly.  It was one of those annoying thing where you know there must be a simple solution but there is no easy way to find it out.  I'm very grateful for your help.  (I agree why do we use Set e = new Excel.Application?)
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now