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
Which conditional statement is the most convenient one to use in the case of multiple conditions in the vbscript language?
How to Convert Hex color code to color name in VB Script?
In html file what is an ideal position to include vbscript?
How will you get a random number between 0 and 1 in vbscript?
write a function to read the items from combobox of Flight reservation & save in excel (QTP)??
Explain about scrrun.dll in vbscript?
Why is it recommended to close the database connection every time after the work is completed?
How will you format a number in percetage format in vbscript?
did any one attended interview in applabs if you had gone through plz tell me the procedure
Which data type/types are supported by vbscript language and what are their specialties?
Which operator can be used to check if two numbers are equal or not in vbscript?
can anyone send me a vb scripts code for clicking on a link and coming back on home page again does the same for many links on a web page.
Hi Friends, I have an issue like the describe below: I'm using QTP and I'm testing on SharePoint. As you knoe, SharePoint has a customize function for user, so that, If I add an object Web Table at the first time, that object was recognized by "index" and "html tag", after that, if someone change the display of web part, the "Index" of my object was changed as well and QTP unable to select that Web Table. Can you guide me how to identify or anyway to keep that Web Table object as unique object? Thanks a lot.
Explain about scrrun.dll?
How can you create a file object to work with the files in the vbscript language?