What does SPLIT and JOIN commands do in Vbscript?
Answers were Sorted based on User's Feedback
Answer / chaitu
Split function is builtin function in QTP
it helps us to divide the string at desired place in a
string
for Ex:-
a = "C:/programmfiles/chaitufolder/chaitanya.doc"
here i want to change the file name of .doc then we can use
x = Split(a,"/") then we will get like this
split function
msgbox x(0) 'it shows this C:
msgbox x(1) 'it shows this programmfiles
msgbox x(2) 'it shows thischaitufolder
msgbox x(3) 'it shows this chaitanya.doc
| Is This Answer Correct ? | 22 Yes | 2 No |
Answer / vj
I disagree with LEO.
SPLIT function is an inbuilt function of QTP.
| Is This Answer Correct ? | 16 Yes | 1 No |
Answer / bhavna khurana
Even I disagree with leo, SPLIT function is an inbuilt
function of QTP. But the normal Split function can't help
you in this case.
Use Instr to find the position of next sequence. e.g.
current="AA"; next="BB"
nextIndex=Instr(0, inputString, next, 1)
| Is This Answer Correct ? | 4 Yes | 1 No |
Answer / mike
It works just fine as quoted above (once you remark out the editorial comments). Whether its native to QTP or part and parcel of VB is irrelevant. The scripter doesn't necessarily care if the command is native to VB, QTP, or both as long as it works. And it works. Kudos to Chaitu for a quick and easy solve.
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / leo
Split function is a vb script function not built into
qtp..if you dont know the answer dont mislead othere....
| Is This Answer Correct ? | 12 Yes | 20 No |
1.Qtp suppots Unix& linx or not 2why qtp suppots shell script.
How do u write a regular expression for date (dd/mm/yyyy) field ?
if the excel sheet specified in script is not there,we get run time error how to handle the error ,please anybody explain me in detail
How to use descriptive programming?
What is the concept of firewalls?
How to recognize and read data from pdf file using Descriptive Programming in QTP?
if you run one test script in internetexplorer the same test you run in mozilla ffirefox is it possible or not how is it.
A web table is having 3 columns(name, salary and checkbox) in qtp How to select a checkbox based on the highest salary of an employee in a webtable.
How can i select multiple values from drop down list using vb script in qtp? and wt is the script for clicking msg box box automatically with a specific time. Thanks in advance...Kalyani.
How to open a new test using QTP?
What is Parameterizing Tests?
Hi anyone having QTP 10.0 licence or crack version pls send me in this mail id mdilipkumar04@gmail.com Regards Dilip