Hello,
How can i capture first letter of any string using QTP.
For ex.. i want "j" in the below string
"john"
could any one explain me?
Is there any function for that?

Answers were Sorted based on User's Feedback



Hello, How can i capture first letter of any string using QTP. For ex.. i want "j" in th..

Answer / uday kumar_anem

str="john"
msgbox(left(str,1))

Is This Answer Correct ?    15 Yes 1 No

Hello, How can i capture first letter of any string using QTP. For ex.. i want "j" in th..

Answer / neeraj chauhan

Dim str, str1
str="john"
str1=mid (str, 1,1)
msgbox str1

Is This Answer Correct ?    9 Yes 4 No

Hello, How can i capture first letter of any string using QTP. For ex.. i want "j" in th..

Answer / veeranki naveen goud

var = Ltrim (" Veeranki Naveen ")
'Ltrim is used to remove the left padded spaces
var2 = mid (var,1,1)
msgbox var2

OR

var = Trim (" John")
va2 = left(var,1)
msgbox var2



Regards,
Veeranki Naveen,
Noida.

Is This Answer Correct ?    2 Yes 0 No

Hello, How can i capture first letter of any string using QTP. For ex.. i want "j" in th..

Answer / naveen

This is simple and easy one when compared to second
str="john"
msgbox(left(str,1))

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

What are the methods used in UFT to handle exceptions or run-time errors?

0 Answers  


How to test whether the navigation i.e. from one page to another is working r not using QTP for web based application. plz explain in detailed or mail the sample code to malepatin@gmail.com

1 Answers  


How many types of parameters are there in QTP and what are they?

2 Answers  


Ehat is the descriptive programing in QTP?

4 Answers  


how do u handle an object with out name in our application using QTP 9.2?

0 Answers   CTS,






How the objecs properties are identified?Tell me in Hierarchical order?

5 Answers   IBM,


They asked by using qtp recording writing scripting

0 Answers   Wipro,


i need to learn the descriptive programming very well so for that what to do am reading the qtp user mannual but it is not so any materials or links with examples i want please help me

2 Answers  


hen do start automation testing after manual testing

1 Answers   Infosys,


Suppose Object name was changed in the application in the second build.I have just modified the name in the Object repository as changes in the Application. Is it possible to accure changes in the script accordingly? If so Suppose I am calling the script through function, Will the changes affect in the script(which is in the function)automatically? If not affected, tell me the solution,How to handle this. How should I change the object property name while using functions

4 Answers   Livetek,


Test cases for Traffic Signals

4 Answers   AppLabs,


suppose take one row in a row 16 columns is there.in 16 columns 16 numbers is there.but i want to get each 3 column number.o/p :5 columns get in 16 columns means. so can anybody write this function? plz send if u know the answer.

2 Answers   Bosch,


Categories