can u write one user defined function for webedit class.
Answer Posted / sunitha
Gneric Function for WebEdit
Values strBrow,strPAge come from object repository
Value strEditboxName is the one which we get on spying the
object and getting its property name.
Value strVal is the one which we want to set in Edit box
function fg_SetValueinEditbox
(strBrow,strPage,strEditboxName,strVal)
set oD = Description.create
oD("micclass").value = "WebEdit"
set strEbox = Browser(strBrow).Page(strPage).Chilobjects(oD)
For iCnt=0 to strEbox.count-1
strName = strEbox(iCnt).GetROProperty("name")
If strcomp(strName,strEditboxName,1) = 0 Then
strEbox(iCnt).set strVal
Exit for
End if
Next
End Function
| Is This Answer Correct ? | 3 Yes | 4 No |
Post New Answer View All Answers
When to use descriptive programming?
what is error and fault in terms of software quality?
how to know no.of mails in our g mail by using vb-script
whenever U using QTP,Test Director, Why we using separate Bug tracking tool?
How many add-ins comes by default with quicktest professional (qtp)?
Explain the views in the QTP GUI?
Explain the features and benefits of quick test pro(qtp)?
I want to open a Notepad window without recording a test and I do not want to use System utility Run command as well. How do I do this?
What is difference between run time object and test object?
what is meant by Implicit and explicit requirements?
What is action?
what is the difference between data driver & data driven and driver script?
how to disable the pop ups through QTP using a script
What is 'sleep' in sync point?
How to get the format of a webedit class in qtp. How can i know that particular webedit accept what type of format like "mm/dd/yyyy" or "$" or Alphanumeric