1vivek12
(vivek verma)
December 18, 2017, 12:03pm
21
the first post was almost correct
see my computer format is est 12/18/2017
now output which i want is from yesterday date with time be 12:00:00 AM (you can consider this as a string)
therefore output i want is this:
12/17/2017 12:00:00 AM; 12/16/2017 12:00:00 AM; 12/15/2017 12:00:00 AM; 12/14/2017 12:00:00 AM; 12/13/2017 12:00:00 AM; 12/12/2017 12:00:00 AM; 12/11/2017 12:00:00 AM; 12/10/2017 12:00:00 AM; 12/09/2017 12:00:00 AM; 12/08/2017 12:00:00 AM; 12/07/2017 12:00:00 AM; 12/06/2017 12:00:00 AM; 12/05/2017 12:00:00 AM; 12/04/2017 12:00:00 AM; 12/03/2017 12:00:00 AM
aksh1yadav
(AKSHAY YADAV)
December 18, 2017, 12:10pm
22
dude that was just a minor format change
anyways see this : Get Last 15 Days datetime.xaml (8.0 KB)
Regardsā¦!!
Aksh
1vivek12
(vivek verma)
December 18, 2017, 12:22pm
23
thanks a ton bro it worked.12:00:00 AM i added at the output.
aksh1yadav
(AKSHAY YADAV)
December 18, 2017, 12:37pm
24
Sorry mate was busy i really forgot. that is also will work with format changeā¦check now instead of appending.Get Last 15 Days datetime.xaml (8.0 KB)
date_time.ToString(āMM/dd/yyyy hh:mm:ss ttā,CultureInfo.InvariantCulture)
Regardsā¦!!
Aksh
1vivek12
(vivek verma)
December 19, 2017, 4:01pm
26
hi bro now problem is i am not able to use this in other workflow.any particular reason?
aksh1yadav
(AKSHAY YADAV)
December 19, 2017, 4:35pm
27
Yes ā¦ u should import System.Globalization namespace in your project first.
Regardsā¦!!
Aksh
1vivek12
(vivek verma)
December 19, 2017, 4:42pm
28
hi i am new to this can u please tell me how.i am not able to pass the date as a string to other workflow .after invoking this one.Please!!
badita
(Mihai Badita)
December 19, 2017, 4:44pm
29
@1vivek12 : academy all the way
1vivek12
(vivek verma)
December 19, 2017, 4:44pm
30
i have refered it but some how i am not able to pass the argument to other workflow dont know why
FYI: This code doesnāt work if you have different years. If you try for the difference between 1/1/2018 and 12/31/2017 you get 364 when it should be 1.
sarathi125
(Parthasarathi)
July 17, 2018, 2:28pm
32
Hi,
try with DateDiff inside invoke code activity as following, it will give you correct result
date2 As Date = Date.Parse(ā12/31/2017ā)
date1 As Date = Date.Parse(ā01/01/2018ā)
ā Determine the number of days between the two dates.
days As Long = DateDiff(DateInterval.Day, date2, date1)
Hey need small helpā¦ i have many question in uipath since i am new . can you guide me how to raise that. Btw i have one question here :
I am copying date from SAP application but since copy activity will copy it as generic type. So i am finding it difficult to add 6(suppose) to that extracted date.
Can you please help me on bothā¦
saleem-shaikh
(Mohammed Saleem Shaikh)
November 28, 2019, 6:11pm
34
Thanks for the sample workflowā¦