Russel Michael on Fri, 23 May 2014 12:57:12
I have got a scenario where I want to perform a CodedUI test and the test should pick the todays date whenever the test runs on the application.
and also the Time which should be 4:30 hours past of the System time.
Starian chen on Mon, 26 May 2014 02:29:25
For this requirement, please refer to this code below:
System.DateTime d = DateTime.Now; d.AddHours(-4); d.AddMinutes(-30); HtmlEdit editControl=[set your control]; editControl.Text=d.ToString();