Hi @Prancia Toh ,
Could you try displaying the Excelrowl2] in a message box?
The syntax has to match with how it is coming from Excel, or more specifically, how the Bot interprets it.
Kind Regards,
Ashwin A.K
Hi Ashwin,
Message box? The Excelroww2] variable was created for the Loop action in line 3 as shown in the screenshot below. 2] is the second index value for the variable itself.
Hi @Prancia Toh ,
I meant to say, could you display the value in a message box like so:
This is to check what format the date is in, so that when we perform the date conversion, we will know the syntax.
Kind Regards,
Ashwin A.K
Hi @Prancia Toh ,
Could you toggle it over to Custom Format and pass in yyyy/MM/dd?
Kind Regards,
Ashwin A.K
Hi Ashwin, here is the format:
Hi Ashwin,
I tried keying in yyyy/MM/dd in Custom Format for Datetime: Assign, and now this message appears:
My local session/session name has always been "Default" all this while though.
Also I have noticed that you are deleting the first row, that isn't necessary if you check "Contains Headers" in the Excel Advanced: Open Action.
By doing so, the bot understands that the first row contains the Headers, which means you can reference them using the Header names itself like so:
$ExcelRow{Date}$ -> Notice the brackets are not square, but curly.
$ExcelRow{"Invoice Number"}$ -> Notice that the header is contained within double quotes, this is done since the header contains spaces.
Kind Regards,
Ashwin A.K
Hi @Prancia Toh ,
Could you verify whether the Session name provided in the Excel Actions and the Loop Action are the same?
If you have provided 'Default" in Excel Actions, please check if the same "Default" has been provided in the Loop Action as well.
If the issue persists, please share few screenshots of the workflow so that we may be in a better position to assist you.
Kind Regards,
Ashwin A.K
I figured out how to solve the error at line 3. I just need to bring the Excel Advanced: Close action outside of the loop.
Now the bot is able to run successfully. Thanks for the suggestion on checking the format of the date!
Thanks for this information. I didn't know about this.
Strange, am facing the same issue and Excel close action is already out of Loop action. Attached snap.
Can anyone help on this?
Hi,
I am getting error : exception occurred while parsing the datetime.
Flow : Opening the excel sheet, reading the data into the data table, running the loop for each row of the data table. the using Date time assign action to custom format : M/d/yyyy for rExcelRecord[12]
Issue : The code is running fine if the data in the excel sheet is more than 6 rows but when I remove the data from excel and keep only 2 rows then it is throwing this error. Which is really very weird.
Could anyone help.