View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
GPrabaka GPrabaka is offline
external usenet poster
 
Posts: 5
Default Forcing Excel Closed

John,
Have you tried this

Dim E1 As Excel.Application

E1.Application.Workbooks(<name).Close()

I am trying to call a web service from an Excel VB application also.
However, when I define the usernameToken before I call the web service, I get
a runtime message "Execution Permission Cannot be Acquired". Have you run
into this?
Thanks
Guha

"John" wrote:

I'm starting a new Vb.Net project and I will be using Office Automation
(Excel only) with a web service to open and prints excel docs for users.

How can I be sure excel closes after it prints and if it doesn't how do I
forcibly close excel without rebooting the server or stopping the Web service?