javascript - How to invoke uft script present in ALM using java script? -
my requirement execute uft scripts based on input given in html page. came know of blogs microsoft has stopped vbs script usage in html. reason want invoke qtp scripts using java script. searched same , didnt find information. if can provide equivalent code in javascript helpful. in short of time experiment client demo near.
dim objqtpapp set objqtpapp=createobject("quicktest.application") objqtpapp.launch objqtpapp.visible=false 'true varusername=document.getelementsbyname('username').value varpassword=document.getelementsbyname('password').value call qc_connect(varusername,varpassword) sub qc_connect(varusername,varpassword,varcustomson) ' objqtpapp.tdconnection.connect "http://dddd.fed.test.com:7117/qcbin", "domain", "project", varusername, varpassword,false if objqtpapp.tdconnection.isconnected objqtpapp.open "[qualitycenter] subject\automated test case development\test",false objqtpapp.test.environment.value("varusername")=varusername objqtpapp.test.environment.value("varpassword")=varpassword objqtpapp.test.environment.value("varcustomson")=varcustomson objqtpapp.test.run objqtpapp.quit else msgbox "cannot connect quality center" end if end sub
thanks, rakesh
your main problem javascript doesn't have equivalent of createobject
.
the browser supports microsoft's alternative (new activexobject("...")
) ie (not edge) , supports vbscript there's no point in porting code javascript.
Comments
Post a Comment