how to reverse the string without using bultin functions(i.e
mean mid,len ,reverse functions)
Answers were Sorted based on User's Feedback
Answer / bantanahal haribabu
using regular exp=======
set Obj=New RegExp
Obj.pattren="[a-z]"
obj.global=true
set obje1=obj.execute(str)
for each letter in obje1
result=letter.value&result
next
print result
| Is This Answer Correct ? | 5 Yes | 0 No |
Answer / chaitanya
set Obj=New RegExp
Obj.pattren="[a-zA-Z]"
obj.global=true
set obje1=obj.execute(str)
for each letter in obje1
result=letter.value&result
next
print result
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / kishan
'how to reverse the string without using bultin
functions(i.e mean mid,len ,reverse functions)
option Explicit
Dim Str, Reverse, i
Str = "India"
Reverse = ""
msgbox len(Str) 'returns 5
for i=len(Str) to 1 step -1
Reverse=Reverse&mid(Str,i,1)
next
msgbox Reverse
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / gabbar singh
Just handling special chars also. addition to chaitanya's answer
Set r=new regexp
r.global=true
r.pattern="[a-z A-Z 0-9 \W]"
srcstring="sdsd1212@!@"
Set s=r.execute(srcstring)
For each letter in s
result=letter.value&result
Next
msgbox result
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / uday
A small correction in the above expression.
Obj.pattren="[a-z A-Z]"
which revers the string with any CAPs Letters also, else it
will ignore the CAPS Letter.
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / pravati
str="This is india"
x=split(str," ")
for i=ubound(x) to 0 step -1
msgbox x(i)
next
| Is This Answer Correct ? | 0 Yes | 0 No |
what are the drawbacks for record and payback in qtp
what is web application and client server application.is there any difference ?
what is frame work of qtp?
Explain the use of action split in qtp?
how to load the *.vbs (or) test generating script in a new machine?
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
What is Distributed testing? How does UFT support it?
Hi All, I need Code For how to export Pass\Fail status to excell sheet without using QC. Thanks Balaji
How do u insert an object during runtime in qtp?
Can launch two instances of qtp on the same machine?
Pls Solve Error(SAP-CRM):- Cannot identify the specified item of the SAPNavigationBar object.Canfirm that the specified item is included in the object's item collection.
There is a name "AJAY" how do u count no.of. "A" in that name ?