find the length of the string without using length function?

Answer Posted / cnu_thatavarthi

Option Explicit
Dim strValue,iCount, intcounter

strValue = "thatavarthi"
intcounter = 0
for icount = 1 to len(strValue)
intcounter = intcounter+1

Next
Msgbox intcounter

'Expected Value
---------------------------

---------------------------
11
---------------------------
OK
---------------------------

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which command is used for writing text on a page?

576


How to open a file. What is the perpose of true and false mode there?

609


how to increasing the numbers in a given text box please write a vb script

1704


How regexp.execute method works?

591


Explain about the support of asp for vb script functionality?

528






In html file what is an ideal position to include vbscript?

812


I have attended Anovatek Software QTP interview. They will give us computer and one web based application with QTP. We have to automate some records (already updated records or new records) using QTP Data driven testing. But we should use for loop? Can any one know how to do data driven testing using For loop?

1549


while using Keyward driven framework in QTPif new requirements are added how to manage it...plz ans

1568


create a form to accept username and password validate the username and password with using message box, display the corresponding user message

2161


what do you mean .ota mobile format

1943


Explain about vb script?

751


how to operate webobjects in a webpage using getobject function and then using generic methods?

2542


What is the use of option explicit in vbscript?

544


What are the differences between sub procedures and function procedures?

520


Which respective symbols are used to separate a line and to break the lengthy statement into multiple statements in the vbscript language?

803