http://qs321.pair.com?node_id=382349


in reply to EXCEL with PERL

If you don't care about saving the open spreadsheets, this snippet will brutally close down all open instances of Excel.

#!perl -w use strict; use Win32::OLE; my $ex = Win32::OLE->GetActiveObject('Excel.Application') or die "No a +ctive objects around\n"; $ex->{DisplayAlerts} = 0; $ex->Quit;

Another way to do it, at least on WinXP would be the system command.

taskkill /f /im EXCEL.EXE