Jump to content

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Find out more here. X


_ExcelBookClose not ending Excel Process

  • Please log in to reply
4 replies to this topic

#1 TSprouse



  • Active Members
  • 8 posts

Posted 10 December 2009 - 09:00 PM

I'm running Win7 (Retail Ver) and Excel 2007

#include <Array.au3> #include <Excel.au3> $oExcel = _ExcelBookOpen("d:\temp\CADStations.xlsx",1) $aryMachines = _ExcelReadSheetToArray($oExcel) _ExcelBookClose($oExcel)

I've tried thesuggestions in this thread... http://www.autoitscript.com/forum/index.php?showtopic=99416&st=0&p=717149

But none of that seems to be working.

does anyone have any other thoughts?

- Travis

#2 Juvigy


    Experimental Drugs Abuser

  • Active Members
  • PipPipPipPipPipPip
  • 1,280 posts

Posted 11 December 2009 - 07:35 AM

$PID = ProcessExists("excel.exe") ProcessClose($PID)

This may also work


#3 TSprouse



  • Active Members
  • 8 posts

Posted 11 December 2009 - 12:30 PM

$PID = ProcessExists("excel.exe") ProcessClose($PID)

Getting the PID and using Process Close did Work, thank you.


Edited by TSprouse, 11 December 2009 - 12:30 PM.

#4 queensoft



  • Active Members
  • 28 posts

Posted 19 May 2014 - 12:35 PM

Old thread, I know, but I have a new addition / solution.


Windows 7 x64, Office 2010, latest AutoIt

Close process using PID did not work for me. If I open an Exccel file after that (using regular double click in Windows Explorer), I get a warning on the left side: Previous file... XLS did not close properly.

But, a simple solution is this - last 2 lines:

$ex01 = _ExcelBookOpen("file.xls", 0) _ExcelBookClose($ex01, 0, 0) $ex01 = ""

After that, exel.exe process is gone from memory in an instant.



    Member of the Hide & Seek world league

  • MVPs
  • 11,521 posts

Posted 19 May 2014 - 02:55 PM

You know this thread is 5 years old?

The Vollatran project



The Basic Con


Those who can't find anything to live for, always invent something to die for.

Then they want the rest of us to die for it, too.

These, and an elite army of thousands, who do nobody any good at all, but do great harm to some, have always collected vast sums from all.

Finally, all this machinery tries to kill us, because we won't die for it, too.

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users