In QTP I have a parameter in a datatable that is a
sentence. I need to take the last word from the sentence
and enter it into a field in a web application. How can I
setup a parameter to enter in just a portion of the
parameter (last word of the sentence) instead of the entire
paramater (whole sentence).

Answers were Sorted based on User's Feedback



In QTP I have a parameter in a datatable that is a sentence. I need to take the last word from the..

Answer / ravimmishra

SystemUtil.Run "notepad.exe", "","",""
iRCount = DataTable.GetSheet(dtGlobalSheet).GetRowCount
msgbox iRCount
For i = 1 to iRCount
sDatColVal = DataTable.Value("Comment")
sFinVal = Split(sDatColVal, " ")
iFinValLen = UBound(sFinVal)
Window("Notepad").WinEditor("Edit").Type sFinVal(iFinValLen) + micReturn
DataTable.SetNextRow
Next

Is This Answer Correct ?    4 Yes 0 No

In QTP I have a parameter in a datatable that is a sentence. I need to take the last word from the..

Answer / zak

Thank you for the helpful response! I included the code in
my script and it is taking the last word from the parameter
and putting it into notepad.

I now need to input this word into a field of the web page
as a security answer. What is the best way to do this? Is
it possible to replace the previous parameter (whole
sentence) with the new parameter (last word of the
sentence)?

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

what is framework and types of framework? Need of framework in automation? write folder strucuture of framework.

3 Answers   HealthAsyst,


tell me abt a time when u had to go above &beyind the call of duty to get the job done

0 Answers  


I want to do Certification course in QTP. For this I request you to suggest the best Tutorial in PDF format, as i'm not in a possition to afford any 'Fee' to join in any institutions. Hence, if possible, kinldy mail PDF file to my mail-ID: chakri_avala@yahoo.co.in Regards, Chakradhar Yadav.

95 Answers   Cap Gemini, Citrix, CTS, IBM, Logistics, QA InfoTech,


How to creating an output value using quicktest professional?

0 Answers  


Hi, Is there any function or vbscript in QTP to clear the cookies,sessions. Please help me in this.

6 Answers  






Explain what the difference between Shared Repository and Per_Action Repository

2 Answers  


what is the framework followed by ur company in qtp

5 Answers  


What are the methods of the TextStream object that are used for reading from a text file?

0 Answers  


Did you use flatfiles in your projects?At what situation you used it?How can you upload flatfiles?

1 Answers  


i am giving.multiple names like ram,raj,san etc....pls enter & search these names in google pade edit box through script... i told to interviewer, using Ms excel & test easily..but interviwer not happy with that answer?

2 Answers   Accenture,


I am sathish , i want to test the Application of JIL.org ,Mobile Emulator ,by using QTP10.0. I am trying to do testing on that Application , but Child Objects are not identified by the QTP. Please can any one help me

0 Answers  


I want to do Certification course in QTP. For this I request you to suggest the best Tutorial in PDF format, and also tell me the best institute and the estimate cost for joining the institute ib delhi NCR. Hence, if possible, kinldy mail PDF file to my mail-ID: kumar123.pathak@gmail.com , Regards, kumar pathak

0 Answers  


Categories