Solved

EXCEL VISUAL BASIC

Posted on 2007-03-23
1
133 Views
Last Modified: 2010-04-30
Hello,

Could someone provide me with code on how to open an excel file without the message asking whether I want to enable macros appearing? Please note that I want to keep macro security as a medium level.

Thanks.
0
Comment
Question by:f19l
1 Comment
 
LVL 81

Accepted Solution

by:
zorvek (Kevin Jones) earned 500 total points
Comment Utility
You can open the workbook inquiry only:

   ExcelApplication.Workbooks.Open Filename:=FilePathName, UpdateLinks:=0, ReadOnly:=True

You can also try disabling alerts:

   ExcelApplication.DisplayAlerts = False
   ExcelApplication.Workbooks.Open Filename:=FilePathName, UpdateLinks:=0

Kevin
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
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…
The viewer will learn how to implement Singleton Design Pattern in Java.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

744 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

17 Experts available now in Live!

Get 1:1 Help Now