• Not Answered

Auto printing Daily report

Hi

I use Excel add -in and create report file but I need to print the report automaticly in special time , How can I do It?

Thanks & regards

 

4 Replies

  • It is possible with Microsoft Task Scheduler and an Excel Macro.

  • In reply to Alfred Pol:

    do you excel macro template?

  • Another possible solution I have used before (with DeltaV Reporter) is to use a Visual Basic Script and run it using Windows task scheduler.  The VBS can open an instance of Excel and print it out.  Example below:

    filename='Report.xls"

    set oExcel = CREATEOBJECT("Excel.Application") 'open an instance of Excel

    oExcel.visible = true 'show the instance, so we know what is going on

    oExcel.Workbooks.Open(filename) ' Opens the Excel Workbook

    oExcel.ActiveWorkbook.Worksheets.PrintOut 'Print current Workbook to default printer

    oExcel.Quit ' Exit Excel Workbook

    set oExcel = Nothing