write a script for get the following result:
username
password
frm the
string1="A=username"
string2="B=password"
Answer Posted / sandeep guttikonda
The Above Posted answer is the very correct one.
Here I would like to show one more option but, not as good
as above one ( Just to tell the other option)
String1 = "A=username"
String2 = "B=password"
We are having 3 good buildin functions in VBscript to work
upon the test messages.
1) Left()
2) Mid()
3) Right()
Here in this case we can use Right() Function to retrieve
the required text.
We can use this function to get a specified number of
characters from the right side of a string.
Syntax: Right(String,Length)
To get username:
Code:
Username = Right(String1,8)
Msgbox Username
As length of us username is 8 I am using 8 in the function.
To get Password:
Code:
Password = Right(String2,8)
Msgbox Password
As length of us Password is 8 I am using 8 in the function.
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
Where you get the run time data table?
what r the verstions from 1st to present (verstions) of mercury tools (like winrunner,QTP,Loadrunner) ? Chandana
how will load the object during runtime?
When and why to use descriptive programming?
What kinds of security (firewalls, encryptions, passwords, etc.) will be required and what is it expected to do? How can it be tested?
How to start recording using quicktest professional?
Explain the types of properties that quick test learns while recording?
How to test background color and dynamic images during run time can you put the check point for moving objects?
Explain calling sub procedure.
How to get the format of a webedit class in qtp. How can i know that particular webedit accept what type of format like "mm/dd/yyyy" or "$" or Alphanumeric
Which scripting language used by quicktest professional (qtp)?
Is it possible to switch between recording modes during a test creation?
How reliable are the site's Internet connections required to be? And how does that affect backup system or redundant connection requirements and testing?
how we implement share object repository in QTP 9.0 without using quality Centre , Explaine in brief
what are the limitations of smart identification in qtp 9.0