3.How to record a word doc using qtp i.e open a word
doc,type something and save the doc can someone send me the
code.
Answer Posted / feroz
Dim objWord
Dim wrdDoc
set objword = CreateObject("Word.Application")
objword.visible = true
Set wrdDoc = objword.Documents.Add
wrdDoc.Range.InsertBefore "Hi Good Morning!"
wrdDoc.SaveAs "C:\Greetings.doc"
objword.quit
Set objword = nothing
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
What is a recovery scenario?
terminal services client
How many types of Automation frameworks are there in UFT? Describe them.
How does you test a weblink which is changing dynamically?
What is synchronization? What are the ways you can synchronize?
what is vmodel?advantages and disadvantages of vmodel?
Where to use Property Let, Property Get, Property Set in UFT
What are the benefits of quick test pro(qtp)?
Describe synchronization point.
Can an action have 2 shared object repositories associated with them? In that case, if two of them contain the same object, which one will be considered?
what type of framework u r using in ur organization
How extensive or customized are the server logging and reporting requirements; are they considered an integral part of the system and do they require testing?
What is the pros and cons between QTP and Rational Robot
When do go for loop condition in test?
when I try to run below script in QTP "totalPages" value is 2. But i am getting error message (Type mismatch: 'totalPages' Line (): "For i=1 to totalPages".) totalPages=Browser("Name:=User").Page("Title:=User").WebElem ent("innertext:=of.*").GetROProperty("InnerText") msgbox totalPages For i=1 to totalPages rnum=Browser("Name:=User").Page("Title:=User").WebTa ble("column names:=User Name;ID;Last Name;First Name").GetRowWithCellText("store4") If rnum>0 Then r=rnum Exit for End If Browser("Name:=User").Page("Title:=User").WebElement ("html tag:=A","x:=471").Click MsgBox "Exit" Next