Forum Discussion
rraghvani
2 years agoChampion Level 3
Somethig like this,
Aliases.Fetchbtn.Click(); // Perform click here
const t1 = new Date(Date.now());
Log.Message("First button clicked at: " + t1.toUTCString());
- nedbacan2 years agoFrequent Contributor
Hello rraghvani , please excuse me, but I am trying to call the function callTimeVariable1() to reuse the time in another script i.e. DurationTime1()
Can you correct my code? There is no error and also nothing in the message log.
Note: TimeVariable1() run fine.
function callTimeVariable1() { return new Date(Date.now()); } function DurationTime1() { const t1 = callTimeVariable1() Log.Message("First button clicked at:" + t1.toUTCString()); aqUtils.Delay(3000); const t2 = new Date(Date.now()); Log.Message("Second button clicked at:" + t2.toUTCString()); aqUtils.Delay(3000); var diff = (t2 - t1) / 1000; Log.Message("Duration Time" +diff); }
Related Content
- 11 years ago
- 8 years ago
- 10 years ago
- 12 years ago
Recent Discussions
- 2 days ago
- 2 days ago
- 5 days ago