Hi I am using StudioX,
I am using Input dialog to enter date from then date to then the robot must extract the inputted date range to excel. For example 08-01-2023 & 08-15-2023.
the robot must insert the data into excel from 08-01-2023 upto 08-15-2023.
please see image below for your reference
Sample Output:
@flashdrive07
use set text variable activity and find the datedifference
Date1=inputstr.split("&“C)(0)
Date2=inputstr.split(”&"C)(0)
use
noofdays=DateDiff(DateInterval.Day,Date1,Date2)
take while loop
condition as counter<noofdays
finaldate=DateTime.ParseExact(date1,(“MM/dd/yyyy”),Globalization.
CultureInfo.InvariantCulture).AddDays(+counter).ToString(“MM/dd/yyyy")
use add datarow activity and pass the finaldate
place set variable as
counter=counter+1
if you face any issues let me know
sorry Shiva, but I don’t understand the logic.
because I am new to using Studio X. can u elaborate more?
Hi @flashdrive07 ,
I think you can use for loop
with dialog to get String value
write cell to excel file by index
each loop we +1 to index
regards,
@flashdrive07
the input dialog box gives you an output as outputdates
make the output into separate variables like
date1=outputdates.split(“&”)(0)
date2=outputdates.split(“&”)(1
later find the difference between the two dates as noofdays
after that use while loop
after doing the above steps let me know
system
(system)
Closed
September 2, 2023, 9:11am
6
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.