8 Replies Latest reply on Sep 30, 2013 11:24 AM by Cristian Vasile

    tabcmd errorlevel

    Hannah Staroselsky

      I created a batch file using tabcmd to export a report in pdf and  then calling a PowerShell  command to send email.

      Here is my code:

       

      cd c:\tabcmd\Command Line Utility

       

      tabcmd login -s http://stats.sfmta.com -u tabs -p t@bsacc

       

      tabcmd export "OrdersGivenTest/ws_OrderGiven" --pdf --pagelayout landscape --width 1100 -f "r:\Automated Reports\OrdersGivenDailyReportBatch"

       

      tabcmd logout

      cd c:\

       

      PowerShell -Command "tabcmd\emailBatch.ps1"

       

      exit

       

      I want to create a condition checking for an error after executing tabcmd export calling different PowerShell command in case of error.

       

      Any ideas?

       

      Thank you!