Suppress messages/warnings using Workbooks.Open


G

Guest

Hi

I'm writing an automated test using C# and Nunit, that are to open an Excel
workbook, insert values, call a macro and then check the resulting values in
a SQL Server table. At present I'm passing a value of 2 to teh Updatelinks
paramter.

As this is an automated test, I don't want user interaction.

The problem I'm having is that there are a few messages that still appear.
Firstly, one saying that remote data is not accessable which appears to be a
warning that an application isn't on my PC. I simply want to ignore this
message. Secondly, the message that the workbook contains links that cannot
be updated and "Continue" and "Edit Links..." buttons.

I need these suppressed. Any ideas how?

Regards
 
Ad

Advertisements

B

Bob Phillips

In your code to open the workbook, set the second argument, updatelinks:= 0

--
HTH

Bob Phillips

(remove xxx from email address if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top