Hi,can anyone tell me How to found the number of 1's and 2's in the given format 1,1,2,2,3,3,4,2 using vbscript
Thanks in advance
Answer Posted / hariharasudhan s
str1="1,1,2,2,3,3,4,2"
A = Split(str1,",")
For i = 0 to ubound(A)
IF A(i) = "1" then
Count1 = Count1 + 1
Elseif A(i) = "2" then
Count2 = Count2 + 1
End if
Next
Msgbox Count1
Msgbox Count2
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
Can any one tell me.......How the test engg's start testing in the compy environment.....real time tester PLSSSS help me i need in depth information regarding this...
What is test object?
what is output value in QTP and how it can be used in automation testing
How does you test a weblink which is changing dynamically?
Explain the concept of how quicktest professional identifies object?
How to save your test using quicktest professional?
HI, pls help me on this, iam not able to capture getcelldata value in javatable... msgbox javawindow("").javatable("").getcelldata(3,3) but it diaplays empty...
What are private functions in QTP? How they can be called from the function library?
how to evalute defects in QTP script?
What is the use of Debug Viewer?
how do u plan test automation?
Name the different types of recording modes?
Hi, I am supposed to automate mainframe application through qtp. I do not know how to start abt it. Can you plz help me in first initializing the process or do you anybody have a guide book or a link which guides me through the process of automating the mainframe applications and things involved in it.
What is synchronization? What are the ways you can synchronize?
What is smart identification in QTP?