Accessing Excel from Word.

S

Sorcerer13

I’m using Office 2010, using VBA to access an Excel Spreadsheet to pic
up some values for my Word document’s Custom Control Listboxes. At th
moment I’m trying to make the Word code “bombproof”, using “On Erro
Goto xxx”. I’ve had a look around to see if there’s a way to see if th
error occurred after I’ve opened the Spreadsheet, but before I’ve close
it. Short of setting a User flag to say it’s open, I can’t see a way t
interrogate the Excel Workbook Object to see if it’s open. Does anyon
know a way?

Code snippets

Dim exWB As Excel.Workbook
Dim objExcel As New Excel.Application
 

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