You are not logged in.
Hi,
I have a set of tasks to be run at different times of a day & at different days. I wanted to schedule it using a batch file which reads the date, time and file path from excel file and run the tasks also send emails after the task is completed or any failures have occurred
Can anyone suggest any code snippet?
I’ve the sample of the excel file below
File name|| File Path|| Date ||Timing|| Email Id
abc || C:\Projects\expensesworkflow.yxmd|| 8nov2017,10Nov2017,17Nov2017|| 16:30, 17:10, 20:05|| xyz@gmail.com, sgfc@gmail.com
bcdf || C:\Projects\censusworkflow.yxmd|| 9nov2017,11Nov2017,15Nov2017|| 12:30, 14:05, 19:05|| sgfc@gmail.com , xyz@gmail.com
fghi || C:\Projects\profitworkflow.yxmd|| 17nov2017,11Nov2017,15Nov2017|| 12:30, 14:05, 19:05|| sgfc@gmail.com , xyz@gmail.com
Offline
XLS files can't be read by batch scripts. If your data is in a CSV file, this is possible; otherwise, I'd recommend using VBA.
Also, I have no idea what your sample data is trying to say.
Offline
Thanks Shadow,
I have no knowledge on VBA so, could you suggest me how is that possible?
Offline
Yeah, Batch is not an option. Batch files can’t read Excel spreadsheets, nor do they have the ability to send emails on their own unlike in VBScript or PowerShell.
If you switch to either of these languages instead I might be able to help with parts of your project, Suhail_07, but unless you can provide accurate test data for us to peruse (such as a sample of the Excel spreadsheet and also a XML formatted template of the required scheduled task) you’ll need to be somewhat accustomed to writing in which ever of those languages you choose.
Offline