18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
how to add the specific number of days to a date which was obtained
I have obtained a field create date which is sysdate, it was obtained from the application using the script _getValue(_byId("GenerationDate")); now i have other fields called start date and end dates.
I need to add 2 or 3 days each to the create date so that those values will be greater sequentially.
EX:
If i get create date as sydate, i need to populate start date as sysdate+1, and end date as sysdate+3.
If i try the above scenario the value is getting concatenated as "11/07/20121" instead i want it as "12/07/2012"
Please help me.
Sagar
I need to add 2 or 3 days each to the create date so that those values will be greater sequentially.
EX:
If i get create date as sydate, i need to populate start date as sysdate+1, and end date as sysdate+3.
If i try the above scenario the value is getting concatenated as "11/07/20121" instead i want it as "12/07/2012"
Please help me.
Sagar
Comments
In java,you can use add() method in java.util.calendar
// For tomorrow's date
calendar.setTime(todaysDate);
calendar.add(Calendar.DAY_OF_YEAR, 1);
Thanks!
there are some javascript date utils out there you could use
Regards
Wormi