Hi, Anybody could tell me What is the script for Reverse of
Given number. Ex:236--632. Thanks in Advance..
Answer Posted / parvez
'You can reverse any string with char, num and spl
characters with this code!
Sub StinrgReverse()
Dim sString, sRevString
sString = InputBox("Enter your string: ")
MsgBox sString
sRevString = fStringReverse(sString)
MsgBox sRevString
End Sub
Function fStringReverse(ByVal sBeforeRev)
Dim aStrSplit, sAfterSplit, sAfterRev, aStrRev
iLength = Len(sBeforeRev) - 1
ReDim aStrSplit(iLength) 'Very Important
For i = 0 To iLength
aStrSplit(i) = Mid(sBeforeRev, i + 1, 1)
Next
ReDim aStrRev(iLength) 'Very Important
For j = 0 To iLength
aStrRev(j) = aStrSplit(iLength - j)
Next
sAfterSplit = Join(aStrSplit, ".")
sAfterRev = Join(aStrRev, ".")
sAfterRev = Replace(sAfterRev, ".", "")
fStringReverse = sAfterRev
End Function
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
how to increase the values in text box in a given text box increament by two values by clicking on button
Explain about tristate constants in vbscript?
Mention the rules for using option explicit statement?
What are the naming conventions while declaring a variable in the vbscript language?
How to open browser in vb script?
What is the use of the date function in the vbscript language?
who will create the object?
Which keyword is used to declare a variable in the vbscript language?
How to assign a date value to a variable?
How to replace junk code recorded by QTP with a mall function.
Hi Friends my Question is very simple,in Manual testing when we click on a hyper link it directs us to the relavent page or it re-directs us to the current page,so there we can easily write testcase but same thing if we do in automation script using QTP & need to generate report using Reporter.report event how we will do it?thanks in advance...
Set srchobj=Description.Create() srchobj("type").value="text" srchobj("name").value="q" srchobj("html tag").value="input" browser("micclass:=google").Page("micclass:=google").webedit (srchobj).Set "qtp" what's wrong in my code pls tell me ? the above code working fine and i got my result pass,now i am trying to run the program it shows general run time error why?pls help me i am in learning stage ?
Which function allows you to instantiate an object given its programmatic identifier or progid?
Which conditional statement is the most convenient one to use in the case of multiple conditions in the vbscript language?
What are class properties?