laziness, impatience, and hubris | |
PerlMonks |
execution of program without dialogue prompting up.by Mr_monk (Initiate) |
on Jan 21, 2008 at 17:36 UTC ( [id://663403]=perlquestion: print w/replies, xml ) | Need Help?? |
Mr_monk has asked for the wisdom of the Perl Monks concerning the following question:
I'm using win::ole module. The following code is used to
create a file new file and save it as .csv. But, when the script is executed
there is a dialogue prompted which says "Do Yyou want to save". How do
I write a code which does not actually pop up this dialogue.
#Excel sheet opening use Win32; use Win32::OLE qw(in with); use Win32::OLE::Const 'Microsoft Excel'; $file = "d:\\test.csv"; my $Excel = Win32::OLE->new('Excel.Application', 'Quit'); $Excel->{SheetsInNewWorkbook} = 1; my $Book_Schedule = $Excel->Workbooks->Add; my $Sheet_Schedule = $Book_Schedule->Worksheets(1); $Sheet_Schedule->Cells(1,1)->{'Text'} = "Success"; $Book_Schedule->SaveAs("$file"); $Book_Schedule->Close;
Back to
Seekers of Perl Wisdom
|
|