Thursday, 21 July 2011

How To Get current date and Time using QTP?

Method :1

Dim dt,mdt
Set dt=CreateObject ("Wscript.shell")
dt.run "cmd /k date"
dt.run "cmd /k time"
Set dt=Nothing

Method :1

Currentdatetime=Now
msgbox Currentdatetime

No comments:

Post a Comment