Please let know the scripts for counting number of repeated
letters in the word. Note repeated letter should not be
count agian.

Ex: If "Hello" is my word... l is coming twice.. it should
count once and print... secong 'l' should not count again..

Answer Posted / sunil

A="Hello"
Set rxp = New RegExp
With rxp
.Global = True
.IgnoreCase = True
.Pattern ="l"
End With

Set colMatch = rxp.Execute(A)

msgbox colMatch.count

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

If I change the object name in one action will it be updated in all the actions? Or not?

590


How do you perform Regreession Testing?

1454


What are the features and benefits of quick test pro (qtp 8.0)?

591


suppose i login into gmail page after that i read all the messages (say 10 messages) i have to send (SAVE) the messages in Html,notepad and i have to replay(Compose) send the messages please give me the code and give mail id so that i can clear my question

1483


Hi, My name is kishan. I have good Conceptual Knowledge on QTP. In order to Boost up my Confidence Level, I want to do a Project oriented Training only on QTP in Hyderabad. Kindly Let me know which is the Best QTP Project Training Institute in Hyderabad. Thanks in Advance kishan

2056






Sql questions to find second max salary and how to use joins

955


What is Cross browser testing? Does UFT support it?

613


whenever U using QTP,Test Director, Why we using separate Bug tracking tool?

1558


What is action? How many types of actions are there in qtp?

607


What is the difference between run time object and test object in QTP?

560


In qtp is it possible to check broken links of a page?

576


How can i check items sorted or not in a weblist ? Give me the script for this...

1571


What is the difference between QTP and WinRunner? Why do you choose only QTP for automation among remaing tools like Rational robot and silk test? Write the VBscript for any functionality in your project ? What is the cost of QTP ? If you entered into yahoo mail with your valid user name then you will get FOR EXAMPLE , " welcome to krishna " on the top of inbo page , how can you test it in QTP? What type of testing you can do, when we gave you 5 screens and how can you test that application? What type of framework you are using in your company and explain it?

1783


Write the script to delete the mail which is at 9th,13th and 18th place in INBOX of Gmail ?

1671


How are actions and functions different in QTP?

648