The string is like POWER STAR PAVAN , write a script for
this how to findout the number of "A" in the string ?

Answer Posted / ravi

str="POWER STAR PAVAN"
len1=len(str)
msgbox len1
str=replace(str,"A", "")
len2=len(str)
msgbox len2
a=len1-len2
msgbox a

Is This Answer Correct ?    1 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to find the path of folder in which the test is saved in qtp?

532


How can you give wait up to 10 seconds in qtp?

586


How to do the scripting. Is there any inbuilt functions in qtp as in qtp-s.

525


Explain about the test fusion report of quicktest professional?

528


I have qtp 9.5 demo ver,I am not able to record the yahoo broeser.so anyone can tell me what setting i have to do in QTP for yahoo brower recording. why its not recognise the object of yahoo browser????

2151






How can i click on any Excel sheet's "H" column with out writing coordinates Ex:Window("Book1").WinObject("Book1").Click 498,14 I dont want to give coordinates like 498,14 Can i open "H" column by writing like Ex:Window("Book1").WinObject("Book1").Click "H" or Ex:Window("Book1").WinObject("Book1").Click "H","1" or Ex:Window("Book1").WinObject("Book1").Click H,1 If i want to click on "Sheet3" of an excel sheet, Can i open like Ex:Window("Book1").WinObject("Book1").Click "Sheet3" Please help me any one

1596


what is vmodel?advantages and disadvantages of vmodel?

1612


Hi.. I want to do parametrization for selecting perticular flighr say XYZ by using local table: criteria: 1.If flight is available msgbox "Flight is available" and then select flight from flight table and click to ok button after that as enter username and ticket no and then stop 2. otherwise msgbox " Flight is not available" and stop Please help me out ..and let me know your responses on dipak.bachhav@gmail.com Regard, Dipak

1618


What is object spy in quicktest professional?

616


After executing the script in qtp suppose i found some script execute successfully and found some error.So how to report the status for both (i.e pass and fail report)in test director. For "fail" We use "defect tab" in testdirector. But for "pass" how to report it to TL.what is the process plz anybody ans

1673


can anyone tell me what to say in interview when interviewer asks about "tell me about your framework in your project"?

1402


How many types of parameters are available in quicktest professional?

519


What kind of performance is expected on the client side (e.g., how fast should pages appear, how fast should animations, applets, etc. load and run)?

590


For QTP Test Engineer, What is his contribution to the Project? Means, As as automation test engineer what is his role in the current project?

1743


how to acess a test in RSA?

1665