KevinDS
(Kevin Da Silva)
November 10, 2020, 2:52pm
1
Hi, I’m having some problems reading an excel file.
The file has this 2 columns when it’s open:
The cells have a date format.
When I used the workbook ‘read range’ activity without preserve format, the date came like this ‘02/01/2018’ and the hour like this ‘0.2644328703703’
When I used the workbook ‘read range’ activity with preserve format, the date came fine BUT the hour like this ‘[$-F401]h:mm:ss AM/PM’
How can I get the Hour like in the excel file
Srini84
(Srinivas Kadamati)
November 10, 2020, 3:11pm
2
@KevinDS
Check as below for your reference
Tutorial : Convert Number to Date Format - #2 by system
Hope this may helps you
Thanks
balupad14
(Balamurugan)
November 10, 2020, 3:36pm
3
Hi @KevinDS ,
Take a look these 2 . It may help you.
To change the format in the excel.
Hi ,
In the release Version 2019.2.0. I have added a new activity called Change Cell Type. It changes the format of the value like below.
[image]
In the Cell Format , can specify the custom format what we have in the excel Like below image.
[image]
Sample : UiPathGoExcel.zip (18.4 KB)
This is the video to configure the package in local.
Here is the link to know about the formats.
Regards
Balamurugan.S
To handle the date time in the datatable.
Videos :
Regards
Balamurugan.S
1 Like
Hi @KevinDS when u write the excel data in form of string as output can u show the output u got ?
KevinDS
(Kevin Da Silva)
May 10, 2021, 9:50am
5
Hi guys, Let me explain again…
I download from SAP this Excel file with this ‘Hour Format’ column:
Then. I need to get this exact hour. So I’ve put a Read Range activity in my sequence. Wich will give me a datatable ase we know.
When I put on the properties preserveFormat Unchecked.
I see the Hour Cells Captured like this:
When I put the properties preserveFormat Checked:
I see the Hour Cells Captured like this:
So… I don’t know what to do… I want to see it like i see it in the excel file
KevinDS
(Kevin Da Silva)
May 10, 2021, 9:53am
6
In the videos you’ve sent before. You already have a good value at the beggining and you’ve changed it to a number and the you’ve changed it again to date. Is not the same. My problem is that i’m not having the right first good value. I don’t know how to capture it
@KevinDS - Is your issue resolved? if not, use this code…