how to count spaces in a given string ex: "this is jagadeesh"
in QTP with simple functional script
Answer Posted / ekapop (scnyl)
Hi,
Const sMY_INFO = "this is jagadeesh"
Function GetTotalSpaceFromText(ByVal sText)
Dim iTotal
Dim asInfo
asInfo = Split(sText, " ")
iTotal = UBound(asInfo)
Erase asInfo
GetTotalSpaceFromText = iTotal
End Function
Msgbox "My Text = " & sMY_INFO & vbCrLf & _
"Total Space = " & GetTotalSpaceFromText(sMY_INFO)
Is This Answer Correct ? | 5 Yes | 2 No |
Post New Answer View All Answers
How to open a new test using quicktest professional?
I am a new tester that needs to create an automatic script involving security questions. On a webpage I need to select a security question(which are random) from a drop down menu, and then input the answer as the last word from the security question. I have the script set-up to automatically select the first security question from the drop down. The problem I am having is trying to insert the security answer. How do I insert the security answer based on the selection from the security question?
What is regular expression?
How to sendKeys in QTP? Diff b/w sendkeys and device replay? Diff b/w function and Sub? Diff b/w Array and List Different Types of running Keys other than Fast, slow,Normal mode Regular expression for http://newtours.demoaut.com Difference between \w and \W How to generate script button Recording Types Different Types of Actions? Using DP performance degrades, If Yes why? How to close all the opened browsers? Diff b/w SystemUtil.Run and invoke application? If qtp not recognized the combo box How to select values from drop down?
I used child objects to get the no of weblist present in the weblist.now i need to select the items present in each weblist ?How to do so
What is checkpoints for quicktest professional?
I have some real time based question.. 1.what are the challenges you have faced in your current project. 2.what are the bugs you found in your current project. 3.what are the strategies you follow to convert manual test cases into automation test cases. 4.how QTP identify two different browsers. 5. When you create a function library and share object repository what are the problems you have faced 6. How to solve the tool tip problem 7.what are the interesting bug you have found in your current project. 8.what is your daily work as a automation test engg. 9. how to create a weekly status report. 10. how many test cases you write,review and execute per day. 11.what are the uses of SQL in automation. 12.How to retrieve the data in html through vb script. 13.If application is very slow how to test the application in qtp.
Is it possible to call from one action to another action in qtp?
How to do call a output parameter from one action to another action??/
Hi Sudhananda, plz send me the QTP framework with any diagram and PPTS . I want to switch to automatio, I done QTP from professional person, but he does not give me his knowledge properly. so pls help me Thaks send me on following address mirajkar.akash@gmail.com
If object is not recognized by qtp but the object is standard object what is your approach?
what is ODC and GDC?
Hi. I have completed B.TECH(CS) , But I will go to "SECURITY CONSOLE OPERATING" [C.C CAMERA abservation]. IF interviwer asks " Why you choose this job ?" What we will say? urgent.........................urgent...........
Explain the concept of object repository and how QTP recognizes objects?
I want to configure the OR and library files to a particular QTP test during run time. Note: OR and Library files are located in Quality Center. Is it possible in QTP? Anybody having code?