Quick test professional

QTP Tips QTP codes QTP Faqs and more

Mohan Kumar Kakarla

295 Comments »

  1. Nice work ra mohan….good….

    all the best…

    murali

    Comment by Murali | February 18, 2008 | Reply

    • Hi Mohan,

      I am new to this blog…
      I have just started leaning QTP, but could not understand how to implement it practically.
      In starting I am trying to record a script on yatra.com booking engine to search the flights and read the valued (Origin City, Destination City, Depart date and Return date) from data table. But I am not able to do this….
      So please guide me how should I start learning QTP

      Regards
      Vishal

      Comment by Vishal Gupta | May 26, 2009 | Reply

  2. Hi,

    Great work.

    Need a help.I am comparing two separate external excel sheets, cell by cell. I mean first cell of first sheet should be compared with first cell of second sheet. Also as the input file may be of any type, I wanted to pass it through a piece of code, where it gets all vacant rows deleted and a proper format is given to this file, before it actually goes as an input to the test.

    Comment by KK | February 26, 2008 | Reply

  3. Hi KK,
    reply sent to your mail.hope it solves

    Comment by quicktestprofessional | February 27, 2008 | Reply

  4. Hi Mohan,

    Could you please help me out how to Accessing MS-Access dB file kept in QC as attachement that is intended for Test Data file?
    So far I am using .xls file that is kept in QC alongwith Test Script. That .xsl is inturn included in the resource settings, so that I am able to access the test data file successfully.

    Thanks in advance.

    Best regards
    Suresh

    Comment by Suresh | February 27, 2008 | Reply

  5. Thanks a lot…absolutely hits the target.

    Comment by KK | February 27, 2008 | Reply

  6. Hi suresh,
    You have to use the Quality Center Open Test Architecture to do this. This guide can be available to down load at

    http://javachip.org/Tutorial/TD%20Tutorial.pdf

    Step1: Use the QC-OTA to down load the ms access file to the local system

    Step2: use some automation code to export the contents of the access db to excel

    Step3. Use datatable.import to import the sheet.

    Hope this will solve the issue.

    Comment by quicktestprofessional | February 28, 2008 | Reply

  7. Hi Suresh,

    Please forgive me dude. I am taking back my words” As per my knowledge No. ,it is not possible to establish ODBC connectivity i.e with DSN/withour DSN, the Access DB which is residing at QC directly”Said your earlier mail.

    Now I am saying ‘Yes” it is possible to establish ODBC connectivity to QC directly. After you asked that question , I have done may experiments from morning onwards to do the same. Finally I got the way to do that. Here are the steps

    create object for fso
    Set fso=createobject(“Scripting.FileSystemObject”)

    2.use pathFinder.Locate method to get the path of the mdb file

    Msaccessfile= fso.getFile(PathFinder.Locate(“[QualityCenter] Subject\xx\xx\msaccess.mdb”))

    3.Use the “Msaccessfile” created in step2 as the path to connection string.

    Sounds great. Thank you very much for ignited my ideas and mind.

    Comment by quicktestprofessional | February 28, 2008 | Reply

  8. Hi KK,

    Great site. Can you tell me how to compare two xml files using QTP.

    Thanks,

    Comment by sam | February 29, 2008 | Reply

  9. Sam,

    Try this code.
    Dim description, filepath
    Set xmlDoc1 = CreateObject(“Msxml2.DOMDocument”)
    xmlDoc1.load(“C:\Documents and Settings\mohan.kakarla\Desktop\1.xml”)’file 1
    Set xmlDoc2 = CreateObject(“Msxml2.DOMDocument”)
    xmlDoc2.load(“C:\Documents and Settings\mohan.kakarla\Desktop\2.xml”)’file 2
    Set ElemList1= xmlDoc1.DocumentElement.ChildNodes
    Set ElemList2= xmlDoc2.DocumentElement.ChildNodes
    If ElemList1.length=ElemList2.length Then’ check weather both xml file has same number of childnodes
    msgbox “Both XML files have same number of Child nodes”

    For i = 0 to ElemList1.length-1

    If ElemList1.item(i).Text=ElemList2.item(i).Text Then
    msgbox “child element:”&i &” is same in both XML files”
    Else
    msgbox “child element:”& i &” is not same in both XML files, In XML file 1, The valueis:”&ElemList1.item(i).Text &” and In XML file 1, The value

    is:”&ElemList2.item(i).Text
    End If
    Next
    End If

    Comment by quicktestprofessional | March 3, 2008 | Reply

  10. Hi Mohan,

    Here I want develop scripts thrh QTP but my application can be installed in remote machine (server)…..

    Here I am trying with VNC software to do that task….

    QTP installed in local machine…
    application in remote machine….

    hope u got my question….so please provide if any new solutions.

    Thanks,
    –suman

    Comment by sumanreddy | March 6, 2008 | Reply

  11. Hello Mohan,
    This is the first time I am seeing your web site. It’s very good and very much useful for a fresher who is interested in learning QTP. Thank you very much for good information sharing.

    Cheers,
    Swetha

    Comment by Swetha | March 6, 2008 | Reply

  12. Well Done Mohan……thanks a lot for all the Information provided and Knowledge shared…….Great Work
    Absolutely Fantastic………Why dont i get such links in Google….if its there i think ….. Mohans link should be right in First 5 or 1O hits displayed by Google

    Comment by Karthik BM | March 6, 2008 | Reply

  13. hello,

    please let me know who to appear for QTP certification and also if possible please send study material and question papers for the same.

    waiting for your reply.

    regards,
    shirish

    Comment by Shirish | March 6, 2008 | Reply

  14. shirish,
    Refer the following link for the info about QTP certification.

    http://www.sqaforums.com/showflat.php?Cat=0&Board=UBB20&Number=439709&fpart=&PHPSESSID=

    Comment by quicktestprofessional | March 6, 2008 | Reply

  15. Hey Mohan,

    You are doing excellent job, I have gone through all your examples which were fantastic, I hope that i will learn many things from your blog.

    Can you just help me, what do you mean by TEST DATA, when that will be prepared? Will it be given by client?

    Srinivas.

    Comment by Srinivasulu Reddy Vallelas | March 12, 2008 | Reply

  16. And also i would like to know few other thing related to QTP,

    What all the roles and responsibilities for QTP tester on the project?

    Can you please precise me as a automation tester, What all the things we will do while executing the project?

    How can i connect TD 5.0 with QTP 8.2, Which i have it on my system? Please explain with proper steps?

    Cheers,
    Srinivas

    Comment by Srinivasulu Reddy Vallelas | March 12, 2008 | Reply

  17. Can you please provide me any example for INOVOKE command in QTP 8.2? I mean to say how will we use this command?

    Srinivas

    Comment by Srinivasulu Reddy Vallela | March 12, 2008 | Reply

  18. Srinivas,

    please do not expect any interview questions here

    Comment by quicktestprofessional | March 12, 2008 | Reply

  19. Hi,

    How to access the inner link inside the DIV.Can I access that using some loops(for,do …while…).

    Pls, help me

    Sample code

    Apparel
    Books and DVDs
    Footwear
    Gifts
    Grooming
    Horse Apparel
    Stable Supplies
    Health Care
    Tack & Strap

    Comment by prasanna | March 13, 2008 | Reply

  20. Hello Mohan,
    Any idea whether QTP 9.2 works against UG graphics and CADD Designs.We are doing lot of Analog and Low level recording at this time.I am not sure if there are special addinns like TE to achieve this in a better way.Let me know when you get a chance. Thanks

    Your Website is Impressive.

    Pradeep

    Comment by Pradeep | March 14, 2008 | Reply

  21. Pradeep,
    as per my knowledge , there is no seperate add-in for CADD designs.
    but you can get TE(TerminalEmulator) addin.

    Comment by quicktestprofessional | March 14, 2008 | Reply

  22. prasanna,

    did you seen how the step will be generated when u click on a link in the recording mode.

    Comment by quicktestprofessional | March 14, 2008 | Reply

  23. Hello Mohan,

    I am working on automating a web based Java application,but all the objects are identified as “JavaObject”. i,e all objects like Buttons, Edit boxes and List boxes are identified as only generic “javaObject” but not JavaButton, JavaEdit etc. For example a button is identified as
    JavaObject(“Button”) and a click operation on that is identified are click of window co-ordinates. Even in an object which looks like List box is identified as JavaObject(“List”) and selecting values as click of co-ordinates. Due to this parameterising values becomes problematic.
    Do you think this is because of the way the application is developed or is there is any other way we can identify the right object. I am aware that QTP has virtual object mapping, but am not sure if it works well in this case.

    Can you suggest a solution?

    Thanks
    Archana

    Comment by Archana | March 14, 2008 | Reply

  24. Archana,
    For web application , irrespective of the technology(atleast .net and java), it should record them as web objects only. i.e webedit, weblist etc.
    May be your qtp is having some problem.Now open your qtp and deselect java addin and try to spy the application and see how it is showing.

    correct me if i am wrong.
    thanks,
    mohan kakarla

    Comment by quicktestprofessional | March 14, 2008 | Reply

  25. Thanks for such a quick response Mohan. This application is an Oracle client which is java based , which is initially launched through web.I probably confused you in the first query.So we may ignore the web part. I have tried this using only Oracle add-in , only java add-in and combination etc. But in all the ways the problem remains as i explained above.All the objects are identified only as JavaObjects . I donno if I am supposed to re install the add-ins or take some additional Plug-ins.

    The Product information is as follows:
    Oracle Applications : 11.0
    Oracle Forms : 4.5.10
    RDBMS : 8.1
    Application Object Library : 11.0

    Thanks
    Archana

    Comment by Archana | March 14, 2008 | Reply

  26. Hey Mohan,

    can you expalin how to build and implement data driven framework in qtp?

    I am really tired of asking this question but nobody explains it.

    Plz plz plz let meknow how to build and implement it step by step as i m an stupid kinda girl..lol

    Thanks In adavnce
    Mamta
    Philadelphia PA

    Comment by Mamta | March 20, 2008 | Reply

  27. Mohan,

    One more thing , I came back in comment section actaully was to appreciate your great efforts!

    Well done bravo! keep it up!

    Mamta

    Comment by Mamta | March 20, 2008 | Reply

  28. Mamta,
    Check your mail

    Comment by quicktestprofessional | March 25, 2008 | Reply

  29. Hi Mohan,

    For the Oracle add-in query raised earlier,when I recorded the application using only oracle add-in the javaobjects got identified appropriately. But Im facing another issue now , i.e the recorded while reexecuting is throwing “Unspecified Error” at some places in the code.

    A sample recorded code is as follows:

    JavaWindow(“Engineering Change Orders”).JavaEdit(“ECO_DEPARTMENT_0″).Set “DSM”
    JavaWindow(“Engineering Change Orders”).JavaEdit(“CHANGES_REASON_CODE_0″).SetFocus
    JavaWindow(“Engineering Change Orders”).JavaDialog(“ECO Customizations”).JavaList(“XXAM_ENG_ECO_SPECIAL_ENG_SPECIAL_ME”).Select “Assignments List”

    But when I re-run the same code, it throws an unspecified error at all the “set” operations. I have used
    Javaedit(…).Object.settext “abc” which works fine.

    But the application flow needs “setfocus” operations , keyboard entries like mictab or micenter as part of navigation. But I am unable to find appropriate methods under the “.Object” to do this. I have tried options like Object.setfocusable(“True”) object.settext “” etc but the required operation of setting the focus on the edit box is not happening.

    Can you please suggest a solution for this!

    My application is on Oracle Forms 4.5 where as Oracle add-in 8.2 says its supports from Oracle Forms 6.0 . Could this be the problem ?
    Also requested HP for a Patch of Oracle and installed the same but of no use.

    Can u please let me know any comments of yours on this…

    Thanks!
    Archana

    Comment by Archana | March 28, 2008 | Reply

  30. Archana,
    Sorry for the delayed reply.
    I do not have any java application in my system to test your code.I can give you some direct and indirect ways.

    # If the .set method is giving error, you can instead go for .Type method.

    # try .Activate method instead of .setfocusable

    if this is also not working use SendKeys with micTab to achieve , explained below.

    #for keyboard entries like mictab or micenter as part of navigation you can go for SendKeys

    Set WshShell = CreateObject(“WScript.Shell”)
    WshShell.AppActivate “Put the label of the browser” ‘ Activate the browser window
    wait(3)
    WshShell.SendKeys “^f” ‘ The caret (^) represents the CTRL key.
    wait(2)

    object.SendKeys(string)
    object A WshShell object.
    string The string value indicating the keystroke(s) you want to send.
    The SendKeys method will send keystroke(s) to the active window. To send a single character (for example, x), use “x” as the string argument. To send multiple characters (for example, abc), use “abc” as the string argument. You can also send special characters such as SHIFT, CTRL, and ALT, which are represented by the plus sign (+), the caret (^), and the percent sign (%), respectively.
    For more information on the SendKeys method and other special keys, such as the backspace or a function key,

    Comment by quicktestprofessional | March 31, 2008 | Reply

  31. Thank You mohan for your suggestions. Have tried a few options earlier, but not supported with application. Shall try the Sendkeys option and update you.

    Thanks again for all your time!
    Archana

    Comment by Archana | April 2, 2008 | Reply

  32. Hi Mohan,
    I have a query.
    The thing is that we have designed an automation framework in QTP that works great.
    Now I would like to encrypt its code so that the actual user cannot copy/change its functional libraries.
    Can this be done, pls let me know.
    Also let me know ur mail id..so that I can contact u regarding this..
    Thanks

    Comment by hims | April 3, 2008 | Reply

  33. Hims,

    It is not possible to encrypt the VBS files.
    In general you can encrypt the vbs files with the aid of some tools but qtp does not able to use them.
    Instead what u can do is create code in dot net and make them dlls and regester them and you can use them.
    But writing code in dot net for the objects(webtable,editbox etc) is not possible.You can write the code in dot net only upto framework level.

    mohan kumar kakarla

    Comment by quicktestprofessional | April 3, 2008 | Reply

  34. Hi
    i am tying to write the value to an Xl sheet and also tring to Sort by Column(accending), can u please Give some comments for each step. so that i can modify the same accordingly.

    Regards
    Sharma

    Comment by Sharma | April 3, 2008 | Reply

  35. Sharma,
    Comments added for the sorting code.
    you can find that here

    http://quicktestprofessional.wordpress.com/2008/02/26/excel-sortingascending-descending-by-rows-and-columns/

    Comment by quicktestprofessional | April 3, 2008 | Reply

  36. hi, thanks but have one small querie

    “Set objWorkbook = _
    objExcel.Workbooks.Open(”C:Documents and Settingsmohan.kakarlaDesktopDocs1.xls”)” is this in one line or tow diffrent lines of code..
    if it us one line .then please do correct the same…

    regars
    Sharma

    Comment by Sharma | April 3, 2008 | Reply

  37. HI dude..

    got the answer , but i need to pass the values using a Variable so that the search should be for that column
    EX: if we have 3 column Age Fname Lname
    i need to sor for Fname First and Age next and the other one for the next time ,so i need to know how can we achive this..

    regards
    Sharma

    Comment by Sharma | April 3, 2008 | Reply

  38. HI Mohan,

    Fantastic job which you are doing.

    Thanks in anticipation

    Warm regards,
    C.M.Reddy Rondla

    Comment by Chandra Mohan Reddy Rondla | April 5, 2008 | Reply

  39. hi mohan..
    first of all thanks a lot for the excel code which i got it from ur site.. That is comparing two sheets and coloring the cells. i have made a little modifications in ur code and used it. Say like i have colored only the used cells in the first row. But in that i am not able to see the border of the cell. I want the border of the cells also. How to make border of a cell visible?? Can u pls help me?

    Comment by Saranya | April 8, 2008 | Reply

  40. Saranya ,
    You can find many things about the excel automation here

    http://msdn2.microsoft.com/en-us/library/aa269740(office.10).aspx

    Comment by quicktestprofessional | April 8, 2008 | Reply

  41. Thanks a lot.. I will find it out.. :-)

    Comment by Saranya | April 8, 2008 | Reply

  42. hi,
    i have one more doubt. How to automate an AJAX layer?? The situation is like this. When we click on an image, a layer pop-ups.We need to validate that layer. Its visible property is always set to true. Can u tell me how to validate it??

    Comment by Saranya | April 9, 2008 | Reply

  43. Is it possible to compare two excel files at run time through QTP ?

    Comment by kishore | April 9, 2008 | Reply

  44. HI,

    Good Job, i have used your XL sheet Compare Function, thanks for the same, I am trying to search a value with in the XL sheet, and the value can be any where with in the XL sheet can you please help me, thank you in advance.

    Mahendra

    Comment by Masha | April 14, 2008 | Reply

  45. Step 1: Create an Excel sheet as 1.xls
    Step 2: Write your desired String which you want to search.
    Step 3: Use below code for searching your above written text ( I have used “Test” for searching the text). Change according your String in the code for this condition If cell.Value = “Test” Then )

    ‘*****************************************************
    ‘Name: KR Testing Solutions
    ‘Code Description: Code for search “Test” in excel sheet and highlighted with Red color
    ‘Date: 14-04-2008
    ‘Website: http://www.kuldeepse.wordpress.com
    ‘*****************************************************
    Set objExcel = CreateObject(“Excel.Application”)
    objExcel.Visible = True
    Set objWorkbook1= objExcel.Workbooks.Open(“D:\1.xls”)

    Set objWorksheet1= objWorkbook1.Worksheets(1)

    For Each cell In objWorksheet1.UsedRange
    If cell.Value = “Test” Then
    cell.Interior.ColorIndex = 3′Highlights in red color if any changes in cells
    MsgBox “Your Text Successfully Found”, vbOKOnly
    Else
    cell.Interior.ColorIndex = 0
    MsgBox “Failed”, vbOKOnly
    End If
    Next

    set objExcel=nothing

    Comment by KR Testing Solutions | April 14, 2008 | Reply

  46. Hi

    thats greate

    thank you for the solution you made my work easy.
    please keep doing the good job thanks again

    Masha

    Comment by Masha | April 15, 2008 | Reply

  47. Hi Mohan Kumar,

    Second time visiting this blog. Very nice advance work for QTP. To Run Multiple test, do you have any suggestion or code for AOM?
    I tried Multi-Test Manager and Built-in Batchrunner but I found they are not very useful.

    Thanks,
    Prashant

    Comment by Prashant | April 16, 2008 | Reply

  48. Hi Mohan,

    I am working on QTP and having a problem with deleting the empty rows in excel sheet. Could you please help me out here?

    Thanks,
    Chandra

    Comment by Chandra | April 16, 2008 | Reply

  49. Prashant,
    The suggesion depends on the req.
    Any how the best way to create batch runner is to create a driver script in qtp with some control mechanism.

    1.make all your actions in all tests to reusable.
    2.create a new test and insert the actions from all test in the order you wanted.

    3. create an excel sheet called control file which has all the actions (tests) with run status flag( weather to run the test or not)
    4. based on the control file flag control calling the actions
    for ex:

    if datatable(“RunStatus”,”ControlFile”)=true then
    RunAction”……..”
    end if
    datatable.setnextrow

    –mohan kumar kakarla

    Comment by quicktestprofessional | April 17, 2008 | Reply

  50. Hi Chandra,
    First tell me how you are deleting the row.
    Are u deleting by selecting the row and press delete in key board?
    If yes then that is the problem.
    The data table this design issue, even u delete the row also it has the reference to that row with empty contents.
    The solution for this is select the row and right click then select edità delete.
    Hope ur problem may solve. Let me know the status.

    Mohan kakarla

    Comment by quicktestprofessional | April 17, 2008 | Reply

  51. Hi can u giv idea about automation qtp frame work for a web application..and hw can design that
    and also can u send some sample framework ???

    Comment by Arunkumar | April 22, 2008 | Reply

  52. Arunkumar,
    It is impossible to send any sample code on framework.
    You can search the net for the same. There are so many frameworks you can develop for web app
    1. FDMA (Fucntionality Decomposition Multiple Actions)
    2. data Driven
    3. Keyword driven
    4. hybrid

    If u have good knowledge in QTP and if u r in bangalore i can guide you.

    Comment by quicktestprofessional | April 22, 2008 | Reply

  53. Hi Mohan,

    Can you share your QTP information with my blog also? So that we can make a single repository. Which can be like Google, Encyclopedia.

    Regards,
    Kuldeep Sharma
    +919910664553
    KR Testing Solutions

    Comment by KR Testing Solutions | April 24, 2008 | Reply

  54. Hi Mohan,

    I have an XML file in a cell in an excel sheet like

    I need to compare this with my Actual output which will appear in an text box in the UI.If the above GetAccUIDResponse,GetAccUIDResult exist in the below actual result then my test script is passed in QTP

    054159622053733cc2-ecc0-48e9-9e08-00f75e42c61b

    Let me know how to compare these two files .

    Comment by Kumar | April 24, 2008 | Reply

  55. Kumar ,
    Could u be brief, what exatly u want.

    Comment by quicktestprofessional | April 25, 2008 | Reply

  56. Hi Mohan,

    Have u ever encountered a bad length error message? I encountered this one while edit an SAPGuiEdit. Is there any way to solve this problems? Thanks in advance.

    Comment by Yuzz | April 28, 2008 | Reply

  57. Yuzz,
    I never worked on SAP application. But i suspect that, the edit box has restriction on length. so when the qtp trying to enter the data which has more than the accepted length of edit, it popups error.
    verify the length manually and also spy the object and look for length property.

    Comment by quicktestprofessional | April 28, 2008 | Reply

  58. Hi KK,

    I have one question.
    when am working with qtp at that time am unable to open internet explorer, its showing some warning message like..
    IE encountered a problem and needs to close.and its shows close and debug buttons.

    could you plse tell me the solution.

    Comment by Nani | April 28, 2008 | Reply

  59. Hi mohan.
    i am a newbie for QTP i have only a bit of its operational knowledge. i want to be an expert but i also dont have much of the programming knowledge. could u plz giv me some docs from which i can strt frm the scratch on the way of mastering QTP.

    Comment by Amit Kumar | April 29, 2008 | Reply

  60. Amit,
    You do not have worry about the good qtp materila, the one which come with installation (pdf documentation) is the best book for QTP. goto start–>qtp–>documentation–>printerfriendly docs here you can find tutorial and user guide with 110,1110 pages each. so start with that and read VBScript documentaion available in QTP help file. Goto discussion forums(ex:sqaforums,TDforums etc) and blogs, you can improve ur self and become an expert.
    -mohan kumar kakarla

    Comment by quicktestprofessional | April 29, 2008 | Reply

  61. Hi Mohan,
    your page gave me good inputs. Could plz give sample code to connect to QC using QTP and Run and update defects through Qtp code.
    Please regarding this.

    Comment by Manohar | May 5, 2008 | Reply

  62. Manohar ,

    I have no ready made code with me.You have to use the Quality Center Open Test Architecture to do this. The guide will give you lots of examples and code snippets.This guide can be available to down load at

    http://javachip.org/Tutorial/TD%20Tutorial.pdf

    Comment by quicktestprofessional | May 6, 2008 | Reply

  63. This site is very helpful to the QTP users.

    Comment by vidyasagar | May 6, 2008 | Reply

  64. Hi mohan,
    I’m trying to record Java based application using qtp 9.5 including the Java addin.
    when ever i’m tring to record the Java application freeze and i must kill the application.
    the Java application is Swing+SWT (Eclipse) based.
    can you assist please?
    Thanks

    Comment by Ilan bar | May 6, 2008 | Reply

  65. Hi Mohan,

    I am using QTP for testing Graphics samples which is new to me.

    I am also new to QTP.Hope u will not laugh.Bcoz when i saw the comments ..all looked like experts to me.

    I am getting this error:
    Cannot find the “Run” objects’s parent “XYZ”(class Dialog).Verify that parent properties match an object currently displayed in your application.

    note:XYZ is my application.
    But sometimes very rarely ,the test is successful when i click on checkpoint properties

    Comment by Devi | May 6, 2008 | Reply

  66. Devi,
    This may happens when u have added the object’s properties with dynamic nature.
    1.Open Object repository, select ur dialog xyz.
    2.Look for the properties and its values which has dynamic value. ex: window ID , hwnd , native class
    3. delete those propeties by clicking Add/Remove button and then deselect those properties

    Let me know the status
    mohan kakarla

    Comment by quicktestprofessional | May 7, 2008 | Reply

  67. Hi mohan,

    I tried what you said.But when i run the XYZ application,when i “run” a sample,during runtime system is waiting for me to click the run..instead of running by itself..can you help me out.

    Comment by Devi | May 7, 2008 | Reply

  68. Hi Mohan,

    First of i am very thankfull to you for the information you are providing for QTP.

    i have one query. i have a table in database and i want data fron that table to Excel sheet using vbscript to use in QTP . when export to excel sheet it should contain data and including the column heading aslo.

    Thank in advance . i aom farword for your responce.

    Comment by anji | May 9, 2008 | Reply

  69. anji,
    1)i have one query. i have a table in database and i want data fron that table to Excel sheet using vbscript to use in QTP
    A)What is the database u r working on? because if u want to do this for Access , you may find the code to export to excel in google. but if you wanted it to work for any database, you have to use normal adodc connection set and record set and iterate throw all the rows , in tha same time open excel through automation object model and and write it there.
    you can get code samples in my blog also.
    2.when export to excel sheet it should contain data and including the column heading aslo.
    A)For this you have to use objAdRs.fields(i).Name in the code where objAdRs is the user defined object instance name for the record set.

    Comment by quicktestprofessional | May 9, 2008 | Reply

  70. Need help … I am trying to encrypt password

    Set objExcel = CreateObject(“Excel.Application”)
    Set objWorkbook = objExcel.Workbooks.Open(“G:\sheet.xls” ,,True,, “Password”)

    when I use QTP password encryption tool and replace ‘password’ with what the QTP tool gives me ‘23423hj341khjbk234′ I get error that password is incorrect

    where should I put SetSecure ?

    Comment by Mark | May 9, 2008 | Reply

  71. Cannot identify the object “Intel Larrabee SDK Sample” (of class Dialog). Verify that this object’s properties match an object currently displayed in your application.
    Line (7): “Dialog(“Intel Larrabee SDK Sample”).Check CheckPoint(“Intel Larrabee SDK Sample”).Check CheckPoint(“Intel Larrabee SDK Sample”)”.

    This is error message i am getting.How do i proceed.

    Comment by Devi | May 9, 2008 | Reply

  72. Devi,
    How you got check checkpoint two times in a single stmt

    -mohan kk

    Comment by quicktestprofessional | May 12, 2008 | Reply

  73. Mark,
    Yes the password is in incorrect. The tool does not have the way to decrypt the passwords , except , the setsecure method , which works only with edit boxes. Qtp does not able to decrypt by itself.
    so do not encrypt your password.

    Comment by quicktestprofessional | May 12, 2008 | Reply

  74. Thanks for your quick responce

    Comment by Mark | May 12, 2008 | Reply

  75. Hi Mohan,

    Cannot find the “Run” object’s parent “Intel Larrabee SDK Sample” (class Dialog). Verify that parent properties match an object currently displayed in your application.

    This is the message.What do i do….

    Comment by Devi | May 12, 2008 | Reply

  76. Hi Mohan,

    Is there any addin to connect QTP 8.2 to QC 9.0

    Comment by Sudhindra | May 13, 2008 | Reply

  77. Devi,
    Post here the properties and its values those are present in the OR for the dialog object.
    -Mohan kakarla

    Comment by mohan Kakarla | May 13, 2008 | Reply

  78. Hey Sudhindra,
    Yes. Addin is required to connect QC with QTP. You can find the location to download at QC home page only.
    Open ur QC and click on Addin Page link, there u will get the info requirements and the download path for the qtp adin

    Comment by quicktestprofessional | May 13, 2008 | Reply

  79. Hi Mohan,

    Properties:
    Description properties:
    text : Cloth
    nativeclass : #32770
    is owned window : False
    is child window : False
    ordinal identifier:
    type,value : None

    I tried deselecting the native class but still the same problem,but occasionally once in 10 times or..so it is successful.

    Comment by Devi | May 13, 2008 | Reply

  80. In the above properties

    text: Intel Larrabee SDK Sample Browser-Security warning.

    Comment by Devi | May 14, 2008 | Reply

  81. Devi,
    I have told u that not to use the dynamic nature properties and also mentioned not to use the nativeclass, since its value #32770 canm change time to time. Read agin the comment 70 and know how to remove that peroperty from the OR.
    Let me know the status.

    Comment by quicktestprofessional | May 14, 2008 | Reply

  82. HI I am prasad i wana some querry when we are using keyword driven then we need to use the actions is it mandatory or not

    and when we are using qtp with quality center where we are conver the test scripts and where we run in batch mode it is automatiolly opens the qc or we use qtp
    plz clarify

    thanks
    Prasad
    9880670803

    Comment by prasad | May 14, 2008 | Reply

  83. prasad,
    I think u have sarted ur qtp recently.You are confusing with keyword framework and confusing us also. There no relation between keyword and action. so how can i say it is mandetory or not.

    Regarding QC, please be brief

    Comment by quicktestprofessional | May 14, 2008 | Reply

  84. Hi Mohan,

    As i told in comment 80,even after removing the native class…still i am getting the error.Can i have your mail id..so i can send the screen shot,If you dont mind.

    Regards
    Devi

    Comment by Devi | May 14, 2008 | Reply

  85. Devi,
    Check ur mail devi_reddy75@yahoo.com
    for the details
    Mohan kakarla

    Comment by quicktestprofessional | May 15, 2008 | Reply

  86. Dear Mohan,

    I’m a newbie using QTP and I’m testing a WebSite that my development team is programming.

    I want to test the login module of the website, because it’s quite complex, and I want to check the database after I run my tests (50 iterations with different data and situations) to be sure that the database is modifying some flags (status) in the right way.

    So, I created a database checkpoint after the previous steps (whole login process), but for some reason, when I create the DB checkpoint, the QTP is taking a picture (ResultSet) of the database, and is comparing that “old” picture with the new data (test run), so, of course is displaying that my tests failed.

    It exists any way to check the database, run by run and checking the “new” data in the DB properly?.

    I would appreciate any answer that you could provide me.

    Miguel Ramirez
    Colombian working in Brazil.

    Comment by Miguel Ramirez | May 16, 2008 | Reply

  87. Mohan,

    I wanted to Automate a report.can you tell me what is the best possible way to automate a report using QTP

    Your help is really appreciated

    Sowmya.

    Comment by Sowmya | May 16, 2008 | Reply

  88. Miguel Ramirez,
    The database checkpoint is not the practical way to automate these situations. I can say DB checkpoint is of
    useless feature provided by qtp. Use ADODB connection and recordset to retrieve the contents and verify with your Test Data.Here is the sample code how to provide a connction to MSAccess Db
    Function obj_UDF_getRecordset (strFileName, strSQLStatement)

    Dim objAdCon, objAdRs

    Set objAdCon = CreateObject(“ADODB.Connection”)

    objAdCon.Open “DRIVER={Microsoft Access Driver (*.mdb)};DBQ=”&strFileName & “;Readonly=True”
    If Err 0 Then
    Reporter.ReportEvent micFail,”Create Connection”, “[Connection] Error has occured. Error : ” & Err
    Set obj_UDF_getRecordset = Nothing
    Exit Function
    End If
    Set objAdRs = CreateObject(“ADODB.Recordset”)
    objAdRs.CursorLocation=3 ‘ set the cursor to use adUseClient – disconnected recordset
    objAdRs.Open strSQLStatement, objAdCon, 1, 3

    While objAdRs.EOF=false
    For i=0 to 4
    msgbox objAdRs.fields(i)
    Next
    objAdRs.moveNext
    Wend

    If Err0 Then
    Reporter.ReportEvent micFail,”Open Recordset”, “Error has occured.Error Code : ” & Err
    Set obj_UDF_getRecordset = Nothing
    Exit Function
    End If

    Set objAdRs.ActiveConnection = Nothing

    objAdCon.Close
    Set objAdCon = Nothing

    Set obj_UDF_getRecordset = objAdRs

    End Function

    Set rsAddin = obj_UDF_getRecordset(“C:\Documents and Settings\mohank\Desktop\Login.mdb”, “Select * from Login”)

    Comment by quicktestprofessional | May 16, 2008 | Reply

  89. Sowmya,
    First of all what kind of reports they are?
    what kind of data will be dsplayed(Dynamic or static)?
    Is there any part of the report contains the data that you have choosen to report?

    based on these info try to analyse the relation between the data given by you to generate report and try to create some optimal functions and reuse them.

    Comment by quicktestprofessional | May 16, 2008 | Reply

  90. Devi,

    I have few queries , please clarify.
    1. When I see your snapshot i found 2 dialogs, one is “File Download – Security warning” which has the Run button and 2nd dialog was not visible in the snapshot to know what might be that, but it looks like “Larrabee SDK sample…”
    Now the qusetion is is the second dialog which is not visible also has the Run button?
    When i see ur error message which is clearly saying dialog “Intel Larrabee SDK sample” is not found.
    yes it is true , bcoz i have not seen any dialog with the name”Intel Larrabee SDK sampl” in the snapshot and qtp is not able to identify the dialog with the properties mentioned in the OR. It might be because of dialog name may be changed.

    So try to add the required dialog again as follows.
    1.Open OR and click on add Objects
    2. add the required dialog to the OR
    3. Check for native class and remove
    4. find out “Regexpwndtitle” property else click on add/remove button and select that property(the value must not be empty)
    5. run again

    Finally excuse for delay in resopnse.

    Comment by quicktestprofessional | May 16, 2008 | Reply

  91. Hi,
    I need to compare cell content of the excel sheet with particular pattern and ignoring the rest of the cntents.

    For example….

    Ex: file1.xls, file2.xls

    Pattern to compare in file1.xls cell (1,1): “This is the message to match” in cell of file2.xls which contains ” My contents is this is the message to match”.

    Here I need to ignore the other string and need to check whether “This is the message to match” is present in file2.xls cell.

    Like this I have around 180 rows to compare.

    The logic which I am thinking is…

    1. Read first cell of file1.xls & file2.xls
    2. Compare them and if it is matching then write “Pass” else “Fail” in second column of file2.xls
    3. Repeat the Step1 and step2 for rest of 180 rows.

    I am looking for QTP script which can perform above logic since I am new to QTP and dont know much apreicate your help on this and reply to bond_369@yahoo.com

    Comment by Jay | May 19, 2008 | Reply

  92. Jay,
    Set objExcel = CreateObject(“Excel.Application”)
    objExcel.Visible = True
    Set objWorkbook1= objExcel.Workbooks.Open(“\\1.xls”)
    Set objWorkbook2= objExcel.Workbooks.Open(“\\2.xls”)

    Set objWorksheet1= objWorkbook1.Worksheets(1)

    Set objWorksheet2= objWorkbook2.Worksheets(1)

    For Each cell In objWorksheet1.UsedRange

    c1=cell.Value

    c2=objWorksheet2.Range(cell.Address).Value

    Set re=New RegExp
    re.Pattern=c1
    re.IgnoreCase=True
    re.Global=True
    ‘MsgBox s
    ‘MsgBox ptn
    ‘MsgBox re.Test(s)

    If re.Test(c2)

    cell.Value=”Pass”
    Else
    cell.Value=”Fail”
    cell.Interior.ColorIndex = 3
    End If
    Next

    set objExcel=nothing

    Comment by quicktestprofessional | May 19, 2008 | Reply

  93. I need to automate an Windows Desktop application which is developed in Borland’s Delphi version 6.0.

    Which Add in I need to install for QTP 9.2 as QTP is identfying all the objects as Winobject??

    Comment by Narendra | May 20, 2008 | Reply

  94. (Sorry this is posted in two places.)

    I have some questions about the “DELETE ROWS FROM XL SHEET” code, since I am trying to use it.

    1. Where do I put the name and location of my excel file?

    Ex: “C:\Names_places.xls” ,”Data” ,”Global”

    2. Where in the above code do I tell it exactly which row in which column to delete?

    EX: I always want to delete Row 1 in the first column, Name. I will be adding this code to the end of my script.

    Thanks!

    Steve

    Comment by Steve Langille | May 20, 2008 | Reply

  95. My alternate email is; slang46188@aol.com

    Thanks again!

    Comment by Steve Langille | May 20, 2008 | Reply

  96. Steve,
    The code given in the post is to delete either rows or columns but not row in a column. so the code will not

    serve ur req. when u see logically ur requirement, there is no point in deleting a row in a column. bcoz

    deleteing a row in a column is nothing but making it empty. right! so use normal code that clears data in a cell
    Function ClearCell (Path,Sheetname,rNum, cNum)
    Set oExcel = CreateObject(“Excel.Application”)
    ‘Sets the application to raise no app alerts
    ‘In this case it will allow a file overwrite w/o raising a ‘yes/no’ dialog
    oExcel.DisplayAlerts = False

    ‘Open Book in Excel
    Set oBook = oExcel.Workbooks.Open(Path)
    Set oSheet = oBook.Worksheets(“Sheetname”)

    oSheet.cells(rNum ,cNum).value=”"

    ‘Save new book to Excel file
    oBook.Save

    ‘Close the xls file
    oExcel.Workbooks.Close()

    End Function

    call ClearCell(“C:\Names_places.xls” ,”Global”,1,1)

    Comment by quicktestprofessional | May 21, 2008 | Reply

  97. can u tell me how to get the number of lines in a document in qtp?

    Comment by kriti | May 21, 2008 | Reply

  98. can you explain by qtp script:

    i) how to compare the string of two different notepad, suppose i know the starting and ending of string,

    ii)how i can fetch the different of string from two different file and create a new file and paste and save, close it..
    regards
    Mthu

    Comment by Muthu | May 21, 2008 | Reply

  99. Hi Mohan,
    I have problem with Autocomplete part of the form in web page, while running the QTP to test the peage it can’t recognize the Ajax Autocomplete texbox, is there any solution?

    Country: ( is a drop down box)
    City:(Ajax autocomplete textbox)
    University:( it depend on which city you’ve choosed)

    evry time while running QTF while it go through the following line (*****)it showed Run Error:

    Browser(“Page 100 – ScreeningWizard”).Page(“Page 100 – ScreeningWizard_3″).WebList(“ctl00$ContentPlaceHolder1$Pers”).Select “Sweden”
    ***** Browser(“Page 100 – ScreeningWizard”).Page(“Page 100 – ScreeningWizard_3″).WebEdit(“ctl00$ContentPlaceHolder1$Pers”).Set “Stockholm”
    Browser(“Nova 100 – ScreeningWizard”).Page(“Page 100 – ScreeningWizard_3″).WebList(“ctl00$ContentPlaceHolder1$Pers_2″).Select “Kungliga tekniska högskolan”

    ERROR: Cannot identify the specified item of the ctl00$ContentPlaceHolder1$Pers_2 object. Confirm that the specified item is included in the object’s item collection.

    I’ll be appreciate if you could help me !

    Comment by Sherry | May 26, 2008 | Reply

  100. Hi

    I have one Doubt in qtp regarding database validating in QTP.
    1. I have created one database ex:emp.db i want to validate the .db file by using QTP. is it possible validate the .db file means ( i want to find how many rows and columns are thr and i need to validate that each and every name and emp id in that file) plz give me the solution for this

    Comment by suseela | May 27, 2008 | Reply

  101. sir,
    I need to install qtp 9.2, please guide me

    Comment by sunil | May 27, 2008 | Reply

  102. Sunil,

    It is as easy as installing any other s/w. try to install and let me know if any issues u will get.
    1. earlier versons should be removed
    2. use 0000-0000000000 (4 zeros- 10 zeros) for evolutiotion purpouse

    Comment by quicktestprofessional | May 27, 2008 | Reply

  103. Hi Mohan,

    I saw your blog today and its really very helpful to lot of people like me who are very new to QTP.

    I am facing some issues with my scipt. Detail is here:

    We are in a page. Clicked on a link. another page opens. Selected a value from a list in the new page. Once we select any value from the new page it closes and we come back to the previous page.

    and now QTP Object spy could not recognise any object on this page so obviously could not click on any of the object on that page.

    If we manually click on some link and go to some other page and come back to this page again QTP object spy could recognise the objects.

    Please give me some direction on how to approach this in QTP script.

    Thanks,
    Nivedita

    Comment by Nivedita | June 2, 2008 | Reply

  104. Hi Mohan,

    Thanks for the support that u r providing through this blog.

    I am stuck in the middle of QTP scripting can u pls help me out.

    I need to click on the print icon in an window page.QTP is identying the object as an Winobject.
    The actual path QTP is identfying is Browser(….).Activex(…..).Winobject(…).

    Please do respond at the earliest.Thanks For the support

    Comment by Narendra | June 2, 2008 | Reply

  105. Narendra,

    The window may be a java or a dotnet window, and u may be not having the addins for that, so it is not recognizing.
    so try to find the type of window and select those addins and try else see the concept of “UserDefined” in object identification in help , it may solve ur problem

    Comment by quicktestprofessional | June 2, 2008 | Reply

  106. Please answer to my query.

    Comment by Nivedita | June 3, 2008 | Reply

  107. Hi!

    using QTP we can make a connection to DB , the resulted recordset contains all the headers and info under them. My problem is how to write this recordset data into a external excel file?

    As we know the same can be done easily in winrunner TSL.

    It will be thankful if any suggestions are there

    –shaan

    Comment by sugumar | June 3, 2008 | Reply

  108. Hi Mohan,
    I am trying to connect to QC from QTP. I could connect successfully. Suppose if i have a script in QTP say 123.
    And i have a test case in QC say TC1. How do i link Script with Test case?

    Thanks
    Uday

    Comment by Uday Bhaskar | June 5, 2008 | Reply

  109. Uday Bhaskar,

    If u r talking about linking manual TC in QC with Test Script in QTP then You can not link like this way.
    Open your manual TC in test plan and click on design steps, under the design steps you can find out a thumbnail (image) called generate script. select qtp in that option. so that it will convert the manual TC to sample qtp script(a template kind of qtp script) say “qc test1″. Now you have the script in QC.
    Open the test “qtp12″that was created in qtp and saveAs the test to the one in QC

    Comment by quicktestprofessional | June 5, 2008 | Reply

  110. hi!,
    how to establish connection with excel file using QTP.

    Comment by vineetkandpal | June 18, 2008 | Reply

  111. Hi!,
    How we can fetch data from excel sheet using QTP.

    Comment by Vineet Kandpal | June 18, 2008 | Reply

  112. Good Work Mohan . All the best. It helps every user a lot ..You have significantly arrange all the topics in a very dynamic fashion..

    Regards,
    Faisal

    Comment by Faisal | June 19, 2008 | Reply

  113. hi my problem is i have thousands statements while execution i got one window in the middile of execution i put one in that if window is exist then goto the first statement for execution is it posible ? i want the solution for this.if posible tell me please…..

    Comment by Chandu | June 19, 2008 | Reply

  114. Chandu,
    Vbscript does not support GoTo stement directly , u have to use with “On Error GoTo” stmt only.
    There are 2 ways to achieve this

    Cosider u have 4 stmts, after 2 stmt u are getting the window , so u have start again from step 1.

    Way 1: Make first 2 stmts into a function and call that accordingly

    Function abc()
    stmt 1
    stmt 2
    End Function
    Call abc()
    if window().exist then
    Call abc()
    End If
    stmt 3
    stmt 4

    Way 2:
    var_Window=True

    while var_Window=true
    stmt 1
    stmt 2

    if window().exist then
    var_Window=True
    else
    var_Window=False
    End If

    Wend

    stmt 3
    stmt 4

    Hope i explained it clear

    Comment by quicktestprofessional | June 19, 2008 | Reply

  115. Mohan,

    U r doing excellent job. I have seen the articles u posted and the replies u r giving to needful. I thought to appreciate u r efforts in giving solutions.

    Keep up the good work.

    Thanks
    Sai.

    Comment by SK | June 23, 2008 | Reply

  116. Hi Mohan,

    Can u pls send me the code to connect to QC and run the test script from QC.

    Thank You

    Narendra

    Comment by Narendra | July 3, 2008 | Reply

  117. hi,
    i have one question in datatable.i get the columname from datatable.if the column name contains “1″(Ex:name1)ihave to replace “1″ as “(1)”(ex:name(1)).is it possible?can u help me on that?

    Comment by mohee | July 3, 2008 | Reply

  118. mohee,
    It can do it in different ways
    1. export data table to excel and use excel automation to modify the contents

    2.use datatable and loop through its contents for each change export it excel and again import to data table

    Comment by quicktestprofessional | July 4, 2008 | Reply

  119. Hi Mohan

    I need to know how to Save the already created MS word file using QTP. If you have any idea, please provide me a QTP code for this

    Thanks & Regards
    Amila

    Comment by Amila Dharmaratne | July 4, 2008 | Reply

  120. Hi

    Sorry for the disturbing. I need this as soon as possible.

    Thanks
    Amila

    Comment by Amila Dharmaratne | July 4, 2008 | Reply

  121. Set wrdApp = CreateObject(“Word.Application”)
    Amila ,
    If you just want to open and save or save as use the following code
    Set wrdDoc = wrdApp.Documents.Open(“C:\Documents and Settings\mohan.kakarla\Desktop\1.doc”)
    wrdDoc.save
    wrdDoc.saveAs(“C:\Documents and Settings\mohan.kakarla\Desktop\3.doc”)
    wrdDoc.close
    Set wrdDoc = Nothing
    Set wrdApp = Nothing

    Comment by quicktestprofessional | July 4, 2008 | Reply

  122. Hi

    The functions that you have used are fine. I am happy to look and use them but I want to know about all the functions for a particular object.

    for example in the following code snippet:-
    Set wrdDoc = wrdApp.Documents.Open(”C:\Documents and Settings\mohan.kakarla\Desktop\1.doc”
    wrdDoc.save
    wrdDoc.saveAs(”C:\Documents and Settings\mohan.kakarla\Desktop\3.doc”
    wrdDoc.close
    Set wrdDoc = Nothing
    Set wrdApp = Nothing

    What are all the methods that are supported apart from save, saveas,open, close.

    Please do the needfull in this regard.

    Thanks
    Srinivas P

    Comment by srinivas potti | July 8, 2008 | Reply

  123. srinivas,
    Thanks for the suggession , but why shiuld i reinvent the wheel. all the methods and properties can be available in help file of the micosoft word. open word click on the tab help. thre u can find Microsoft word visual basic reference, there u can find all the methods u are looking for.

    Comment by quicktestprofessional | July 8, 2008 | Reply

  124. Hi Mohan,

    First time I am visiting your page its really great, Good job… :)

    I was stuck in a problem with OTA API Quality center 9.2. I have created a vbs file which I scheduled in my test lab machine, this vbs file run the couple of test suites in Quality center daily and finally generates a .xls report with the execution time, date, status and test case names.

    After generating the report I have to send the report to the responsible persons.

    I have created vbs script which is supposed to attaché the attachment in Quality center and send the mail attachment to the recipients, every thing is working fine but attachment is not coming..

    For time being I am using the another script which is sending the mail attachment through Lotus, but in this case I have to open my lotus notes every time then only it will work

    In OTA reference mentioned that we can send the Attachment lists in Quality center as a variant array.

    We are using Quality Center 9.2 and QTP 9.0.

    I have posted this issue in lots of forums but I haven’t get any solution hope you can solve my problem. Please find the below code which I used.

    Dim QCConnection
    Dim attachFact
    Dim theAttachment
    Dim attachList
    Dim AttachmentList()
    Dim HasAttachs
    Set QCConnection = CreateObject(“TDApiOle80.TDConnection”)
    QCConnection.InitConnectionEx “http://test/qcbin”
    QCConnection.login “uid”, “psw”
    QCConnection.Connect “domine”, “project”
    Set TSetFact = QCConnection.TestSetFactory
    Set tsTreeMgr = QCConnection.TestSetTreeManager
    nPath = “Root\testfolder”
    Set tsFolder = tsTreeMgr.NodeByPath(nPath)
    Set attachFact = tsFolder.Attachments
    Set attachList = attachFact.NewList(“”)
    For Each theAttachment In attachList
    msgbox theAttachment.FileName
    Next
    If Not HasAttachs Then
    Set theAttachment = attachFact.AddItem(Null)
    theAttachment.FileName = “C:\temp\Report.xls”
    TDATT_FILE = 1
    theAttachment.Type = TDATT_FILE
    theAttachment.Post
    End If
    ReDim Preserve AttachmentList(attachList.Count – 1)
    Dim i
    i = LBound(AttachmentList)
    For Each theAttachment In attachList
    AttachmentList(i) = theAttachment.ServerFileName
    i = i + 1
    Next
    Dim fName
    For Each fName In AttachmentList
    msgbox “The AttachmentList element is ” & fName
    Next
    QCConnection.SendMail “sarat…@gmail.com”,”",”Test”,”Hello”,
    AttachmentList
    msgbox “bye”
    QCConnection.Disconnect
    QCConnection.Logout
    Set QCConnection = Nothing

    Thnaks,

    Sarath

    Comment by sarath nalla | July 8, 2008 | Reply

  125. hi mohan,

    i am new to testing .actually i don’t understand how to set the shared object repository mode.pleasetell me the navigational statements for shared OR in qtp 9.2.i didn’t see any options to select per action , shared OR.
    SEND ANSWER TO MY MAIL.

    Thanks,
    shilpa
    shilpa_koukuntla@yahoo.co.in

    Comment by shilpa | July 9, 2008 | Reply

  126. shilpa,

    There will be no option to swich between shared and per action OR in qtp 9.2 . OR was drastically changed in 9.2
    Read the help document , u will gwt better picture

    Comment by quicktestprofessional | July 9, 2008 | Reply

  127. Hi, Mohan

    Do we have an option to Read the Data From PDF Format?If So can you please help me out with the same

    Regards
    Mahendra

    Comment by Mahendra | July 10, 2008 | Reply

  128. Hi, Mohan

    I must appreciate your effort, i need your help in connecting Test director with the QTP. Can u give me such material or anything that can be helpful in doing that on my mail.

    Thanks

    Sanjay Dabhi

    Comment by Sanjay | July 11, 2008 | Reply

  129. Sanjay,
    You need to exploree the Test Director Open Test Architecture (TD-OTA) to do this . you can download it from the link http://javachip.org/Tutorial/TD%20Tutorial.pdf

    Regards,
    Mohan Kakarla

    Comment by quicktestprofessional | July 11, 2008 | Reply

  130. how to connect to sql server from qtp and work on it

    Comment by raja | July 12, 2008 | Reply

  131. Hi Mohan

    I came across about your site today and its fantastic.

    Thanks for sharing your experience and knowledge

    Comment by Muralidhar Vadakattu | July 12, 2008 | Reply

  132. raja,
    The code that given for connecting access database is also works for any database. only thing u have to modify is the connection string. so change the connection string to respected database goven in the folloing websitr.
    http://www.connectionstrings.com

    Mohan kakarla

    Comment by quicktestprofessional | July 13, 2008 | Reply

  133. Hi Mohan,

    I need to Save As already opened Word file. I do not need open Word file using QTP script. Mean, currently its open. I need to save this file to new location with new name.

    For example:
    Steps
    1. Manually Open word file
    2. Enter some lines to that file by hand
    3. Save this file to specific folder(C:\Test1\Test1.doc) using QTP script. (No need to open word file using QTP)

    I use this code

    Set l_objWD = GetObject( ,”Word.Application”)
    l_objWD.ActiveDocument.SaveAs “C:\test1\test1.doc”
    l_objWD.Quit

    This is give syntax error, but its work.

    If there any way to save already opened Word file other than this, without given any syntax error?

    Please help me to fined this.

    Thanks
    Amila

    Comment by Amila Dharmaratne | July 14, 2008 | Reply

  134. hi mohan,
    i want to take value in the middle of datatable.is it posible?(we have value in 10 rows but i want 5th row value only and i want to execute from 5th row)is there any ways to follow like this?

    cheers
    chandu.

    Comment by chandu | July 14, 2008 | Reply

  135. Hello Mohan,

    We have recently started to use QuickTest Professional 9.0 to streamline our translation testing. I am having a bit of trouble figuring out how to compare a text property of an object with an external one (via Excel or XML). What I want to do is make sure that the entire translated string is being displayed and not cut off. We currently keep all our translated strings within Excel files with two columns; first one with the object name and second with the string.

    Is there anyway I could create a test that would check the text that is visible on the program against what it should be in the Excel file? If you could e-mail me back on this it would greatly appreciated. Thanks,

    Mike

    Comment by Mike | July 14, 2008 | Reply

  136. Hello Mohan,

    I am working on automating a web based application. A table in the webpage is identified as image. There is a button in one column of each row clicking which displays the details on that row. All objects like Buttons are identified as imagebuttons and a click operation on that is identified are click of window co-ordinates. For example:

    Browser(“Home Insurance”).Page(“Home Insurance”).Image(“Select”).Click 51,6

    Due to this parameterising values becomes problematic.Is there is any way we can identify the right object.

    I tried Virtual object method as well. But i am not able to do it successfully and it gives the following error: “failed to create virtual object definition”

    Could you please suggest a solution?

    Comment by Venkat | July 15, 2008 | Reply

  137. Venkat,
    If the web table is recognizing properly , then you can use the child object method to retrive the image in a perticular cell and click on that

    Comment by quicktestprofessional | July 16, 2008 | Reply

  138. Rich,
    Even when you do it manually also the QC will not overwrite the existing file , it is the feature itself. instead you can always delete the file and then attach the updated one.you can find the code to delete in this blog itself.

    Comment by quicktestprofessional | October 17, 2008 | Reply

  139. Thirupathi,
    Regarding pdf automation , you can not dirctly interact with it from QTP. u need to use AOM model, u can find the more info at
    http://www.advancedqtp.com/wp-content/uploads/ScriptingQTP/CH16%20-%20Accessing%20PDF.pdf

    Comment by quicktestprofessional | October 17, 2008 | Reply

  140. Lavanya ,
    Regarding placing the checkpoint in a seperate VBs file and they are not working, one of the reasons may be you are using the peraction OR and while the checkpoint executes, it will cosider the current action’s OR whom it is getting called and that action does not have the required definintions of the checkpoint in the OR.

    Comment by quicktestprofessional | October 17, 2008 | Reply

  141. I need to provide an estimate to the client for a new project.Can you please let me know Whether QTP supports for the following browsers and what are the versions that QTP supports for the below browsers.

    1)Firefox
    2)IE
    3)Mozilla
    4)MsnTV
    5)Netscape
    6)Opera
    7)Safari

    Will QTP identify the objects developed in Macintosh,Vista and Unix.

    Please let me know ASAP.

    Comment by Narendra | October 17, 2008 | Reply

  142. Hi Mohan,
    Can you please provide me more details on DotNetFactory? Not examples, some therotical documents or any good website which can throw more light on DotNetFactory…
    Your all articles of QTP are good. I’m the regular visitor of your site.

    Comment by uma | October 18, 2008 | Reply

  143. uma,
    There are no documents available for the DotnetFactory in the internet so far. If u find find anything please provide the URL here. As per the dotnet factory, this blog is the only source which had comprehancive examples.

    Comment by quicktestprofessional | October 20, 2008 | Reply

  144. Hi Mohan Kumar,
    I am going through your blog from quite some time and it has been a knowledge repository for me when it comes to QTP. thanks a lot

    Can you please help me in solving the below issue. I am struggling with this from quite a long time.It will be a great help, if you can give me some solution.

    ‘My aim is to rename the file using DOS in QTP.
    DIM oShell,oFolder,lres,lTimeStamp
    oFolder = “C:XYZ”
    lres =”RES.txt”
    lTimeStamp = “RESULT!.txt”

    Set oShell = CreateObject (“WSCript.shell”)
    oShell.run “cmd /K CD & oFolder /K”
    oShell.run “ren & lres & lTimeStamp”

    Comment by Naga Praveen | October 20, 2008 | Reply

  145. Mohan, a small correction for the above query.

    oFolder = “C:\XYZ”

    I have tried to run the above program but only the first command is getting executed.

    Comment by Naga Praveen | October 20, 2008 | Reply

  146. Hi Mohan,
    Can you please provide me the script for counting the number of WedEdit’s in one webpage,and also to capture the names of webedits.

    Thanks in advance

    Comment by kalyani | October 21, 2008 | Reply

  147. Naga Praveen,

    First of all y u r going for DOS when we have FSO object model, any how its ur requirement

    I have seen ur code it has lots of mistakes
    1)You r not making the command proper i.e u r using double cotes(“) when using variables EX: “cmd /K CD & oFolder /K”
    2) The shell object each and evry time it is running , it will opens a new command prompt and trys top executs, so do not use two oShell.run stmts , combine them into one

    Here is the working code

    DIM oShell,oFolder,lres,lTimeStamp
    oFolder = “C:\Program Files\Mercury Interactive\QuickTest Professional”
    lres =”LinkCls.vbs”
    lTimeStamp = “Link.txt”

    Set oShell = CreateObject (“WSCript.shell”)
    oShell.run “cmd /K CD ” & oFolder &”& ren “& lres &” “& lTimeStamp

    Plz let me know if it serves ur problem

    Comment by quicktestprofessional | October 21, 2008 | Reply

  148. kalyani,
    Please search the blog before u comment,the post related to getting child objects already there, u can find it here

    http://quicktestprofessional.wordpress.com/category/descriptive-programming-and-child-objetcs/

    Comment by quicktestprofessional | October 21, 2008 | Reply

  149. Hi Mohan,

    Can you help me in creating a sample script to search for a value in excel.

    Thanks In Advance,
    Bhagawati

    Comment by Manu | October 21, 2008 | Reply

  150. Bhagawati,
    Just done that , u can find it in below URL
    http://quicktestprofessional.wordpress.com/2008/10/21/search-for-a-particular-value-in-excel-using-find-in-view-menu/

    Comment by quicktestprofessional | October 21, 2008 | Reply

  151. Thankyou verymuch Mohan

    Comment by Manu | October 21, 2008 | Reply

  152. Hi Mohan,
    I installed QTP 9.5 in my system Successfully.when open QTP9.5. it is showing default action as Reusable Action.But in QTP 9.1 by default action as Action.I recorded some script for my product using QTP 9.5 and run that script, it’s throws General Run Error.
    Please clarify this and comments are invited as soon as possible.

    Thanks & Regards
    Naresh A

    Comment by Naresh | November 25, 2008 | Reply

  153. Hi Mohan,

    How to intercahge and save the XML Element in the XML file using QTP
    For example xml file like this

    i need like below using QTP script(VB Script)

    Please clarify this.
    Thanks,
    Naresh A

    Comment by Naresh | November 25, 2008 | Reply

  154. Hi Mohan,
    In my application I have the date in the following format “07MAR2008″. When I tried to write date add function QTP is reading it as a string. How to convert it into date format and do adddate function and again convert back into the same format and update into the application. Is it possible. Please help me. I am using 9.2 version of QTP
    Thanks
    Sowmini

    Comment by Sowmini Devi | November 27, 2008 | Reply

  155. Hi

    I just was going through your resume for some opening.I saw the link and opened it just to kill time.Being an IT recruiter i have gone through n number of resumes.But this one thing of yours is seriously the differentiator.

    It is a good attempt of out of box thinking.your help to others is sincerely appreciated

    Thanuja

    Comment by R Thanuja | November 28, 2008 | Reply

  156. Sowmini Devi,
    Following is the code that will convert string date into required date and add a value to date and converts back to the string date

    strDate=”07MAR2008″
    strDate= replace(replace(strDate,Right(strDate,4),”/”&Right(strDate,4)),left(strDate,2),left(strDate,2)&”/”)
    strDate=dateadd(“d”,1,strDate)
    msgbox strDate
    msgbox day(strDate)&MonthName( Month(strDate),true)&year(strDate)

    please let me know if any short method is avialable.

    Comment by quicktestprofessional | November 28, 2008 | Reply

  157. Thanks Mohan,
    Its working, amazing, I asked somany people and nobody guided me properly, actually I am struggling with this issue from more than a month and atlast I got it through you. I appreciate to for helping all of us.
    Thanks
    Sowmini

    Comment by Sowmini Devi | November 28, 2008 | Reply

  158. Hi Mohan,
    One more doubt please don’t mind.
    I have a web table where I search for a client with Last name and the table display the names in a webtable with first name, last name and also client_ID. In all those only Client_ID is unique. I need to check the checkbox with the client_ID for which I am using the following code. But it is taking a lot of time to check for the client_ID. Is there any other way I can code to get the desired client with client_ID.

    Dim LineNumber
    LineNumber = Browser(“INGENIUM”).Page(“INGENIUM_17″).Frame(“Frame”).WebTable(“Select”).GetRowWithCellText(DataTable(“Client_ID”, dtGlobalSheet),3, 0)
    LineNumber = LineNumber – 1
    Browser(“INGENIUM”).Page(“INGENIUM_17″).Frame(“Frame”).WebCheckBox(“SELECT-T[" & LineNumber & "]“).Set “ON”

    Thanks
    Sowmini

    Comment by Sowmini | November 28, 2008 | Reply

  159. Hi Mohan,

    Your are doing a greate job by helping others.
    Thanks

    I need to help to compare two different excel sheets (source and destination) and store the difference information in a third excel sheet.

    Your help is highly appreciated.

    Thanks
    Prasad

    Comment by Prasad | December 1, 2008 | Reply

  160. Prasad,
    Use the following code to comapre two excels and write the difference in third one.

    Set objExcel = CreateObject(“Excel.Application”)
    objExcel.Visible = True
    Set objWorkbook1= objExcel.Workbooks.Open(“C:\Documents and Settings\kmohankumar\Desktop\1.xls”)
    Set objWorkbook2= objExcel.Workbooks.Open(“C:\Documents and Settings\kmohankumar\Desktop\2.xls”)
    set newWorkbook=objExcel.Workbooks.Add
    Set objWorksheet1= objWorkbook1.Worksheets(1)

    Set objWorksheet2= objWorkbook2.Worksheets(1)
    Set objNewWorksheet= newWorkbook.Worksheets(1)

    For Each cell In objWorksheet1.UsedRange
    If cell.Value objWorksheet2.Range(cell.Address).Value Then
    objNewWorksheet.Range(cell.Address).Value=cell.Value
    objNewWorksheet.Range(cell.Address).Interior.ColorIndex = 3′Highlights in red color if any changes in cells
    End If
    Next

    set objExcel=nothing

    Comment by quicktestprofessional | December 4, 2008 | Reply

  161. Hi Mohan,

    How are you? I am trying to validate PDF content with QTP 9.1 without any Add-In. Could you please give some idea how to validate PDF contents and if any logo present in a pdf file.

    Thanks in Advance…

    Kamal

    Comment by Kamal | December 4, 2008 | Reply

  162. Hi Mohan,

    While running test batch runner, I am getting only last test results. If I want to get all the tests results what would i do?

    Comment by ganesh | December 6, 2008 | Reply

  163. hi friend,
    i am doing a project(of bank dealing in reports) in that i want to define a property to the qtp9.5 but it’s a dropdown. i mean in that dropdown in that there are four option i want to hit one option from that dropdown. and secdonly i want to see whether the data brought in from database to the report is correct in this case can you please help me out…. waiting for your answer and it would be very kind of you if you can mail the answer to my mail id…… thank you very much ….

    Comment by shkhar | December 6, 2008 | Reply

  164. Hi Mohan,

    How are u.
    Can you please help me to change color of text excel sheet using QTP.

    Can you please send your email id.

    Thanks
    ggchowdari

    Comment by G. G. Chowdari | December 7, 2008 | Reply

  165. G. G. Chowdari,

    “please help me to change color of text excel sheet using QTP” do you mean to change the color of the text in cells of excel sheet.if yes here is the code.

    Set objExcel = CreateObject(“Excel.Application”)
    objExcel.Visible = True
    set newWorkbook=objExcel.Workbooks.Add
    Set objNewWorksheet= newWorkbook.Worksheets(1)
    objNewWorksheet.Range(“A1:A3″).Interior.ColorIndex = 3′ To select multiple cells
    ‘(or)
    objNewWorksheet.Cells(1,2).Interior.ColorIndex = 3′To select single cell
    set objExcel=nothing

    Comment by quicktestprofessional | December 8, 2008 | Reply

  166. ganesh,
    Batch runner always gives u the results based on the settings in result location window. open any test click on run, a window will appear, select new results option . run it once. then run the batch runner.

    Comment by quicktestprofessional | December 8, 2008 | Reply

  167. Hi mohan,

    I didn’t get u. please can u explain once

    Comment by ganesh | December 8, 2008 | Reply

  168. Hi,

    Pls send me the script, to validate the email id in qtp 9.1

    Thanks

    Comment by Suresh | December 8, 2008 | Reply

  169. Hi Mohan,

    Myself again Narendra here ….
    Please clarify a issue which is bugging me up all over the day.
    I have a Master script in which there are multiple Reusable Actions.
    My requirement here is I need to call the test settings(.vbs),Object Repository(OR.tsr)during runtime without adding the settings in File –> Settings–>Resources

    I have used the below script.But after the execution of this Function(QCTestSettings) the execution is coming to the First line and throwing an “Invalid procedure call or argument”.Can u pls clarify this issue?

    Dim App
    Set App = CreateObject(“QuickTest.Application”) ‘ Create the Application object
    App.Launch ‘ Start QuickTest
    App.Visible = True ‘ Make the QuickTest application visible
    ‘ Make changes in a test on Quality Center with version control
    If App.TDConnection.IsConnected Then ‘ If connection is successful
    Call QCTestSettings()
    Else
    Call SharedRepSettings()
    End If

    Function QCTestSettings()
    Set App = CreateObject(“QuickTest.Application”)
    App.Launch
    App.Visible = True
    App.Folders.RemoveAll
    App.Folders.Add”")
    QC_ORpath=”Path in QC”
    RepositoriesCollection.RemoveAll()
    RepositoriesCollection.Add(QC_ORpath)
    call ExecuteFile (“Registration.vbs”)
    call ExecuteFile (“Generic_Functions.vbs”)
    call ExecuteFile (“Resuable Functions.vbs”)
    End Function

    Comment by Narendra | December 10, 2008 | Reply

  170. Hi Mohan,
    how to export run time data table values (from multiple scripts) into one excel sheet and store it in Quality Centre? Is it possible?
    Sowmini

    Comment by Sowmini | December 11, 2008 | Reply

  171. Hi Mohan Kumar, Good day to you.

    I am trying to find out ways that QTP can help our application testing in terms of automation.

    HP provides various options of QTP evaluation licenses & I am not sure which would require for us.
    Just to brief about our application, it is web based supported by Peoplesoft & ORACLE DB.

    Could you please advise which evaluation software(s)to be used for our type of testing that involves mainly regression testing.

    1) HP QuickTest Professional 9.5 Evaluation
    2) HP QuickTest Professional for Java 9.1 Evaluation
    3) HP QuickTest Professional for .Net 9.2 Evaluation
    4) HP QuickTest Professional for Oracle 8.2 Evaluation 5) HP QuickTest Professional for Peoplesoft 8.2 Evaluation
    6) HP QuickTest Professional for VisualAge 8.2 Evaluation 7) HP QuickTest Professional Web Services Add-in 9.2 Evaluation

    As I am new to Test Automation, could you please help?

    Thanks
    Best Regards
    Karthik

    Comment by Karthik | December 11, 2008 | Reply

  172. Karthik,
    For the pople soft web application , u need to use HP QuickTest Professional for Peoplesoft 8.2 and not required to use any other addins.

    Comment by quicktestprofessional | December 11, 2008 | Reply

  173. Narendra,
    In the u are using call ExecuteFile (”Registration.vbs”), which may gives the problem in the following situations

    If u are not adding the relative path here in App.Folders.Add(“path”), it will give the error “Invalid procedure call or argument”

    so, please provide the relative path in the App.Folders.Add
    (or)
    use the full path in the ExecuteFile (”C:\QTP\Registration.vbs”).

    Let me know if ur problem got solved

    Comment by quicktestprofessional | December 11, 2008 | Reply

  174. Thanks Mohan Kumar for information.

    Have a nice day.

    Best Regards
    Karthik

    Comment by Karthik | December 12, 2008 | Reply

  175. hmm good post…I have read this somewhere,But this is more informative.

    Comment by ruchi | March 6, 2009 | Reply

  176. Hi,
    I need your help. I need the link to download
    QuickTest Professional Web Services Add-in 9.1
    Could you please mail it to me?
    Thanks & Regards,
    Ruhi

    Comment by Ruhi | March 9, 2009 | Reply

  177. Hi Mohan,
    I need ur help.
    I am trying to export two queries output from databse to an excel using QTP.
    After exporting my QTP global sheet is still showing the database output in the datatable of QTP.
    How to get my original Global sheet where I populate database names and passwords in order to execute some more queries and export the db output to excels?

    Thanks in Advance,
    Sushmitha

    Comment by Sushmitha | March 11, 2009 | Reply

  178. Hi all,
    how to check tab order from top to bottom and bottom to top in dialog box (windows applicaion)pls let me know the answer Immediately ?that dialog box have edit boxes,winlistviwer and buttons.?

    Comment by Chandu | March 11, 2009 | Reply

  179. Hi,
    I am QTP learner. I want to write script for gmail login and user open one of the mail from inbox and sign out.Every time my script going to fail. i use Descriptive prog and Reguler Expression. So how should I solve this problem.

    Waiting for ur reply.

    This my script
    browser(“name:=Gmail: Email from Google”).Page(“title:=Gmail: Email from Google”).WebEdit(“name:=Email”).Set(“akash.juventus”)
    browser(“name:=Gmail: Email from Google”).Page(“title:=Gmail: Email from Google”).WebEdit(“name:=Passwd”).Set(“sbs_2003″)
    browser(“name:=Gmail: Email from Google”).Page(“title:=Gmail: Email from Google”).WebButton(“name:=Sign in”).Click

    browser(“name:=Gmail – Inbox (4) – akash.juventus@gmail.com“,”title:=Gmail”).Page(“title:=Gmail – Inbox (4) – akash.juventus@gmail.com“).WebElement(“innertext:=rahul (6)”,”innerhtml:=rahul”).Click

    Comment by akash | March 12, 2009 | Reply

  180. I am reading your blog posts for a long time and this is my first comment at your blog because i like the post :) Please keep it up.

    Comment by Denenmis Tarifler | March 12, 2009 | Reply

  181. Hi,
    Issue : I have a excel sheet with a column name ScanDate with data type general.. how can i convert the column data to a Datetime format(dd/mm/yy hh.mm.ss AM/PM.) using VBScript
    I will be really greatful..Plz help me

    Comment by Nihar | March 20, 2009 | Reply

  182. Hi Mohan,

    How can i check with QTP/VBScript whether an img tag got an alt attribute or not?

    Thanks in advance,

    Matthew.

    Comment by Mathew | March 22, 2009 | Reply

  183. Hi,

    I want to run my QTP scripts in different remote machine without installed QTP in that machine.

    Note: but i should not call my local machine’s QTP for this script execution.

    Do you have any idea?

    Comment by Anitha | March 24, 2009 | Reply

  184. I want to say that i agree with the original posters comments.Ca someone else make a better point?

    Comment by clyde bendagraph | March 25, 2009 | Reply

  185. Hi Mohan,
    Great Job!

    Truly your site is highly informative and your work is appreciating. Thanks for knowledge sharing.

    I need your help.

    I am not able to connect QTP with “MySql” database.
    Can you please publish a sample code or send me a sample code on my mail id?

    thanks in advance

    Comment by Dharmendra | March 25, 2009 | Reply

  186. Very nice information. Thanks for this.

    Comment by ben cotten | March 25, 2009 | Reply

  187. Well, iam foreing, iam not very good writing in english, i just wanted to say thanks for this !

    Comment by Michael Inmuebles | March 27, 2009 | Reply

  188. Nicely said, I enjoy the time that it took to research and write. Great work.

    Comment by Government Loan Modification Program | March 28, 2009 | Reply

  189. Hi, I want to run my local system scripts from other machine without installed QTP. Note: without disturbing the local system.

    Comment by Anitha | March 30, 2009 | Reply

  190. Hi Kakarla,
    How are you?
    I am automating an application with QTP 10.0 version.

    My question:
    There is a label(items 1-10 of x visible).
    a link (Next>(11-y)) appears, if the x>10.

    How should i give the condition from label.

    Please respond.
    Thank you.

    Comment by Mohan | April 2, 2009 | Reply

  191. I have the same problem does any one has found solution?

    QTP v9.5.0.0 Build 194
    Add-Ins: ActiveX, Java, Oracle, Visual Basic, Web, .NET, WPF
    OS: Microsoft Windows XP Service Pack 3 (Build 2600)
    Application Java Version: Java 1.6.0_05 with Swing

    QTP is not able to recognize/record the objects for the application designed in 1.6.0_05 with Swing. We tried all the following things:

    1) We tried invoking the application by QTP Run and Record setting but QTP failed to recognize the objects (Go to Automation -> Record and Run Settings -> Java -> Open the following application when a record or run session begins

    2)We selected all the options under File -> Settings -> Java.

    3)We tried altering the settings under Tools -> Options -> Java -> Advance but still QTP didn’t recognize the objects.

    4)We tried altering the Environment variable _JAVA_OPTIONS and JAVA_TOOL_OPTIONS as well.

    NOTE
    _JAVA_OPTIONS = -Xrunjvmhook -Xbootclasspath/a:C:\PROGRA~1\HP\QUICKT~1\bin\JAVA_S~1\classes;C:\PROGRA~1\HP\QUICKT~1\bin\JAVA_S~1\classes\jasmine.jar
    IBM_JAVA_OPTIONS = -Xrunjvmhook -Xbootclasspath/a:C:\PROGRA~1\HP\QUICKT~1\bin\JAVA_S~1\classes;C:\PROGRA~1\HP\QUICKT~1\bin\JAVA_S~1\classes\jasmine.jar
    JAVA_TOOL_OPTIONS = -agentlib:jvmhook
    _classload_hook = jvmhook

    5) We coppied jvmhook.dll file from C:\Program Files\HP\QuickTest Professional\bin\java_shared\bin to

    6) When we do Object Spy the only meaningful TO Property we get is
    Nativeclass : SunAwtDialog
    object class : SunAwtDialog
    regexpwndclass : SunAwtDialog
    regexpwndtitle : ShipSite.CustomerMenu

    Thanks
    Manikanta

    Comment by Manikanta | April 2, 2009 | Reply

  192. Enjoying reading your blog. Hard work always pays off.

    Comment by compositeeffectz | April 8, 2009 | Reply

  193. Hi Mohan,
    1) I want to work on the remote machine .QTP is intalled on my machine and i have to automate the application in remote machine through RDP and NX client connection.how can i be record or indentify object in the remote desk top.
    2) In those machine one OS is Windows and other is linux i have work on windows but LINUX i dont know.Please tell me how to work on LINUX OS in remote machine

    I dont know how to do, i am facing serious problem with both the issueplz help me out with this problem. will be very thankful

    Comment by upendra | April 8, 2009 | Reply

  194. Hi Mohan,,
    yesterday i posted a query ,but i got deleted .please help me its urgent.

    1) I have to work on the remote machine.Qto is installed on my machine and i need to record and automate the application present on the remote machine,can u please tell me how can it be done.
    2)I have to also work in LINUX enovirnoment ,bit i have never worked on QTP in LINUX OS .please guide me how to do.

    Would be very thankful to u.

    Comment by upendra | April 9, 2009 | Reply

  195. upendra,

    Are you talking about the cutrix remote machne, if yes you have to install the qtp on the citrix whre the application located. please go through the following lnk to get more info.

    http://www.sqaforums.com/showflat.php?Cat=0&Board=UBB20&Number=556924&Searchpage=4&Main=526581&Words=remote+machine&topic=&Search=true#Post556924

    Comment by quicktestprofessional | April 9, 2009 | Reply

  196. Hi Mohan ,
    We are not using Citrix machine We are using 3 types of connection Remote desktop connecttion,VNC and NX xlint for connecting to the other database .
    In the Remote desk top we need to connect to the remote desk top and automate the application.But the QTP in installed on my machine not in the remote machine.
    Same is the case with the NX Client I tried to automate it but it is not able to recognice the ogject in the NX client

    Comment by upendra | April 9, 2009 | Reply

  197. It is a simple remote desktop as we connect through accesories and ip address………..how can i use QTP on that when QTP in installed on my machine and not on the remote machine which have the application

    Comment by upendra | April 9, 2009 | Reply

  198. Hi,

    I am new in QTP.
    Please send step to step learning material if you can, for the nacent QTP user.
    My mail Id is richa.singh.mn@gmail.com

    Thanks in advance.

    Comment by Richa Singh | April 9, 2009 | Reply

  199. Hi mohan.
    i am a newbie for QTP i have only a bit of its operational knowledge. i want to be an expert but i also dont have much of the programming knowledge. could u plz giv me some docs from which i can strt frm the scratch on the way of mastering QTP.

    One problem that I am facing is that Active screen is not coming. For that wt to do?

    I have try many things which where on the net but not got.
    wt to do?

    Comment by Richa Singh | April 9, 2009 | Reply

  200. Hi All,
    How to get the line number which i am currently executing in QTP?

    Example :

    2 ————
    3 ————
    4 abc()
    5 ————
    6 ————

    The purpose of this function abc should be to get the line no (i.e., 4)

    Is it possible??
    Please Reply me ASAP.

    Regards,
    Judit

    Comment by Judit Raj | April 9, 2009 | Reply

  201. Hi All,
    How to get the line number of the function invocation in QTP?

    Example :

    2 ————
    3 ————
    4 abc()
    5 ————
    6 ————

    The purpose of this function abc should be to get the line no (i.e., 4)

    Is it possible??
    Please Reply me ASAP.

    Regards,
    Judit

    Comment by Judit Raj | April 9, 2009 | Reply

  202. Well, like i readed alot of your post i wanted to say thank you at least one time.

    julie.

    Comment by Julie Straus | April 12, 2009 | Reply

  203. Hi Mohan
    I have a small question. My application is in .NET environment, and we work with session variables. When ever we need the session variables needed to be changed that will be done by developers with config files. Is there a possibility to change the session variables by initiating the config files through QTP?
    One of my session variable look like this.

    Session(*hciCustomerName)=”"
    Session(*hciIncidentXTO)=”xto”
    Session(*IsAgriliance)=”"

    Sowmini

    Comment by Sowmini | April 13, 2009 | Reply

  204. Hi Mohan

    I am using QTP9.5 to do a data driven test on a dot net application, after 3 iterations the application freezes.

    any potential reasons and help is much appreciated.

    thank you

    Comment by maruti | April 14, 2009 | Reply

  205. Hi Mohan,

    1) Can u tell me wat is Silent installation of QTP and how to do it.

    2)I send a mail regarding RDPand i got this responce can you please tell me the meaning of this statement.
    “Are you guys using VMs to deploy your machines? If so, you could probably getting away of testing against the VM image and then cookie cut the rest of the environments”

    Comment by upendra | April 21, 2009 | Reply

  206. Hey Mohan – thank you so much for posting all this knowledge online – this is like a treasure chest, most informative and comprehensive – better than anything I have ever seen. You are a true scholar. I was wondering if you could advise me on the following matter:
    Is it possible to read data from command prompt? I need to create a test for the process, where user actions result in messages being displayed in the console. Is there any way for QTP to capture/read these messages?
    Thank you very much,
    Yan

    Comment by Yan | April 22, 2009 | Reply

  207. Yan,
    The easiest way is to use GetVisibleText method to get the data from the command prompt.
    here is the example:

    msgbox Window(“C:\WINDOWS\system32\cmd.exe”).GetVisibleText(-1,-1,-1,-1)

    Hope this will solve the query.

    Comment by quicktestprofessional | April 22, 2009 | Reply

  208. Hi Mohan,

    Recently, we have got new requirement to use QTP so i’m novice in QTP. When I was searching for QTP tutorial and found this website in between.

    Could you please help me out? Thanks a lot in advance.

    Ram :)

    Comment by Rambabu | April 22, 2009 | Reply

  209. Hi Mohan,

    I really stuck up with automation of DevExpress Treelist control. I have to find a node in the treelist and perform a rightclick or leftclick on that particular node and a contextmenu will be displayed.

    I am not able to perform click on a node. Is there anyway to get the location of the node.

    Comment by praveen | April 24, 2009 | Reply

  210. Hi Mohan,
    I have a small problem in OTA,the problem is to find the Test Name of a Test Case given its Test ID in the Test Plan Module,also i dont know the folder structure of the test plan,so my problem is to first search for the Test ID right from the Root directory locate it and then extract its Test Name.

    Is there a way to search for the test id from the root.

    Comment by prasad | April 24, 2009 | Reply

  211. I searched on google and I had a hard time located the right info….until I found your blog.

    Comment by No Reciprocal Directory | April 24, 2009 | Reply

  212. Useful information. Helped me figure out few things. Keep up the good work.

    Comment by SEO Consultant India | April 26, 2009 | Reply

  213. I Love your blog on google and have read many of your posts. Excellent. Keep up the good work!!!

    Comment by Paul Daniel | April 26, 2009 | Reply

  214. Hi Mohan,
    great work. Big thanks to you. Very useful information. keep up the good work.

    Comment by Manoj | April 27, 2009 | Reply

  215. Hi Mohan,
    Can you please tell me how to create response file for silent installation of QTP.Do u have the code for it .

    Comment by upendra | April 27, 2009 | Reply

  216. Looks like I found another great site to add to my feed reader. Mark

    Comment by marko hansen | April 30, 2009 | Reply

  217. Keep up the good work. Look forward to reading more from you in the future.

    Comment by rossgeller | May 4, 2009 | Reply

  218. Hi,
    I’m unable to run this script. I have msgbox that displays “test” as message output. I copied and pasted the code:

    Set sh = CreateObject(Scripting.Shell)
    sh.Popup message content, 5, msg header, (0+4) “test”

    It says Invalid Character.
    Plz help.

    - A

    Comment by Abhijeet | May 6, 2009 | Reply

  219. Hi Mohan

    Working on .net application SwfTable control using QTP 9.5 with .net addon under Windows XP operating system.

    I am trying to open a new window”Security properties” through double click on a table cell.

    When I replay the script QTP is doing nothing other than highlighting the cell.

    More over QTP is reading the cell data by coordinated rather the cell text.
    My test case is to pass the cell data through external data file(say note pad/excel), then after reading the data from this external data source QTP needs to double click on that particular cell text to open the “Security Properties” window.

    When I double click on the pointed security , it opens the below screen”Security properties”. Below is the code to open the “Security properties window”.

    SwfWindow(“InvestmentManager – Automation”).SwfWindow(“Targeter – CDO Fund”).SwfTable(“preTradesGrid”).SelectCell 17,1

    But during replay QTP is doing nothing other than just highlighting the cell without opening the security properties window.

    But If I replaced the “SelectCell” with “Activatecell” method QTP is opening the Security properties window which is fine. But I want to open the “Security properties window” based on the names which will be read from external data file(say excel) in cells rather than the coordinates.

    Ex: SwfWindow(“InvestmentManager – Automation”).SwfWindow(“Targeter – CDO Fund”).SwfTable(“preTradesGrid”).ActivateCell “Liability 20071215” where in the
    “Liability 20071215” needs to read from the external data file.

    If you need further information I can send you an attachemnet.

    Response is much appreciated.
    thank you
    maruti

    Comment by maruti | May 8, 2009 | Reply

  220. Good work mohan especiall Excel Automation.

    Comment by Naresh | May 8, 2009 | Reply

  221. HI Mohan,
    Thanks for help and support always.great job I need ur help.
    My scenario is that i need to login and the click on the link and sub link which have this notation (a square with plus sign in it +link name).When i try to record it through QTP then it is not able to rcord the left panel (link are on the left panel and after clicking these link search button comes in the right panel) of the browser,and soon as it comes in the right panel it is able to indentify.Is there any way or code so that QTP will be able to click on the +link and expand them .wat approach should i follow so that it is able to recognize the link.I tried with tab and arrow but browser dosent support .Type micTab.
    I am not able to expand the link in the left.wat should i do
    When i m identifying the link throuhj Object spy then it show this flow

    Browser: name
    Page:name
    Webtable:name
    Image:name

    It is identifyting it as image

    Please help me out

    Comment by upendra | May 13, 2009 | Reply

  222. Very nice information. Thanks for this.

    Regards,
    Mike

    Comment by Make Money Online Blog | May 13, 2009 | Reply

  223. Hello Mohan,

    I need to validate a value of an edit box that is present in a weblist. “01″ is the value displayed, But when i tried getcelldata(row,col) it is retreving null value. . The webtable will be like “I should get the value from 1st row 1st column and than i should be able to get the value from 1st row 3rd column (which will be a web edit). Please help me in this

    Thanks,
    Bhagawati
    bhagawati.manukonda@gmail.com

    Comment by Bhagawati | May 13, 2009 | Reply

  224. Thanks for sharing to others.

    Comment by Jujur Penglihatan | May 17, 2009 | Reply

  225. Thanks for sharing to others.

    Comment by Jurutera Kapal Angkasa | May 17, 2009 | Reply

  226. Your post was really interesting and its nice to see some good quality information, but would you recomend any where to get more information about this?

    Comment by Alesha | May 18, 2009 | Reply

  227. just stopped by to say i really liked your site – you’ve obviously put some hard work into it!

    Comment by liz thwaite | May 19, 2009 | Reply

  228. Not everyone can share good information on the net. Have a nice day, pal.

    Comment by moues | May 21, 2009 | Reply

  229. Hi All,

    I am using QTP 9.5 and selected Web and java Add-ins as my application is a java application. There is a JavaTree like object in my application. But while spying it gives
    Browser(“Project Management”).Page(“Project Management”).Frame(“frmapplication”).JavaApplet(“frmAppletApplication”).JavaObject(“objNavTreeView”) I want to click on a particular tree link.
    Can anyone help me in this ASAP.

    i tried with JavaApplet(“frmAppletApplication”).JavaObject(“objNavTreeView”).Object.expandAll
    JavaApplet(“frmAppletApplication”).JavaObject(“objNavTreeView”).Object.collapseAll it is working fine but not able to select or click on a text or node in the tree.

    Regards,
    Judit

    Comment by Judit Raj | May 21, 2009 | Reply

  230. Hi Mohan,

    I am using QTP 9.5 and selected Web and java Add-ins as my application is a java application. There is a JavaTree like object in my application. But while spying it gives
    Browser(“Project Management”).Page(“Project Management”).Frame(“frmapplication”).JavaApplet(“frmAppletApplication”).JavaObject(“objNavTreeView”) I want to click on a particular tree link.
    Can you help me in this ASAP.

    i tried with JavaApplet(“frmAppletApplication”).JavaObject(“objNavTreeView”).Object.expandAll
    JavaApplet(“frmAppletApplication”).JavaObject(“objNavTreeView”).Object.collapseAll it is working fine but not able to select or click on a text or node in the tree.

    Regards,
    Judit

    Comment by Judit Raj | May 21, 2009 | Reply

  231. Dear

    I have strated QTP, but i don’t know how to start writing script, plz do help me

    Comment by prabu | May 21, 2009 | Reply

  232. Hi Mohan,

    I am new to this blog…
    I have just started leaning QTP, but could not understand how to implement it practically.
    In starting I am trying to record a script on yatra.com booking engine to search the flights and read the valued (Origin City, Destination City, Depart date and Return date) from data table. But I am not able to do this….
    So please guide me how should I start learning QTP

    Regards
    Vishal

    Comment by Vishal Gupta | May 26, 2009 | Reply

  233. Hi Mohan,

    Plz let me know if we can read PDF file with QTP.

    Comment by Pavitra Tandon | May 27, 2009 | Reply

  234. Very helpful! Look forward to reading more ;)

    Comment by Barry | May 31, 2009 | Reply

  235. Hi

    Take an example of GOOGLE. Whenever a search is made, search count is shown in Bold. However count is no more displayed there in Label or Text field otherwise getting count dynamically was easy. How can we get search count dynamically in Data table or any variable whenever a new search is made.

    Thanks

    Comment by Wahaj | June 4, 2009 | Reply

  236. Very nice information. Thanks for sharing.

    Comment by david stern | June 4, 2009 | Reply

  237. I found your blog on google and read a few of your other posts. I just added you to my Google News Reader. Keep up the good work. Look forward to reading more from you in the future.

    Comment by viaggi | June 6, 2009 | Reply

  238. Hi Mohan,

    Hope you can help me out in finding a solution for the below question.

    My application has several pages and each page has some common text. I wanted to perform an action only when that text is shown. I added that WebElement into the object repository and moved it under the root. I scripted such that if the WebElement object exist then pass the script othewise fail. But sometimes the script recognises the WebElement and sometimes it won’t. Not sure why? I have used regular expression for that web element. Is there any way that I can do rather than adding that web element to each and every page of the object repository?

    Looking forward for your reply.

    Thanks,
    Ganesh

    Comment by Ganesh | June 11, 2009 | Reply

  239. A very nice niche blog, and a good design there sparks Simplicity yet complex algorithm of the internet. Thanks man You rock .

    Comment by Gabby | June 11, 2009 | Reply

  240. Hi Mohan,

    Really Good Work yar… After reading ur answers learned a lot thank very much..

    Thanks & Regards,

    Sreekanth
    9885987468

    Comment by Sreekanth Peetla | June 12, 2009 | Reply

  241. Can I have the script for ” How to capture the unread mailz from the gmail(or yahoomail) inbox.

    Thnaks & Regards,

    Sreekanth
    9885987468

    Comment by Sreekanth Peetla | June 12, 2009 | Reply

  242. I was actually looking for related business sites, but stumbled across yours on Google!! I’m actually quite interested so will keep an eye out for updates :)

    Comment by free ipods | June 16, 2009 | Reply

  243. I am planning to do QTP Exam. Could anyone send me dumps or set of question papers or some links to check my confidence level

    Comment by novic | June 16, 2009 | Reply

  244. Hi Mohan,

    You are really doing a great job.As I am not working more on QTP as my current profile but desires to get exposure on that. This website is helping me a lot to do my job and getting knowledge of QTP.

    Thanks and Best of Luc !!

    Comment by Tulika | June 17, 2009 | Reply

  245. Very well thought out and informative. I’m sure many others enjoy reading this too, but are just a little scared to post – anyway – thanks again!

    Comment by MySpace Friend Adder | June 21, 2009 | Reply

  246. Hi,

    please can U help me . we are facing below problem with QTP 9.5 :

    urs is web-based java application. i am facing problems while identifying objects. QTP able to identify all object at page before selecting list-item but not after selection of list-item.while spying able to get one browser and page object but not all objects….

    please help me on this…

    Comment by raja | June 21, 2009 | Reply

  247. Hi Mohan,
    i am new to this blog,
    i have a query regarding QTP.one of my friend has developed a framework in QTP on application which basically places order for online shopping.As per the functionality if there are is ant error while placing order, an email including the snapshot is send to the respective e-mail id which is entered while placing an order.we are facing an issue that the snapshot which we receive attached to the mail is shown as blank and the subject line s also wrong.we are not able to diagnose this issue
    could you please help us out in solving this issue

    Thanks,
    Hari

    Comment by Hari | June 22, 2009 | Reply

  248. Hi MOhan,

    First of all let me congratulate for doing a gr888 job!!
    Could you please let me know that suppose i have N no. of users and i have to Divide the users in 4 different xls based on alphabets,i.e.A-E, F-L, M-S and T-Z IN QTP..
    How will i do that?

    Thanks,
    Shruti

    Comment by shruti | June 30, 2009 | Reply

  249. Hi,

    In my web application, two windows are opened with same title. I need to identify both of the windows seperately. Please clarify this.
    Browser: IE 7

    I have tried by adding in the OR, smart identification, ordinal identifiers also.

    Thanks,
    Bhagawati

    Comment by Bhagawati | July 2, 2009 | Reply

  250. Hi Mohan,
    How can i loop through ADO recordset?.I have three columns in my
    recordset.First column has all blob fieilds which i want save as xml
    file with names from that of the second column.

    Here is my code:

    Set dbc_conn = CreateObject(“ADODB.Connection”)
    dbc_conn.Open “Provider=OraOLEDB.Oracle;Data Source=(DESCRIPTION=(CID=GTU_APP)(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=xx.xx.xx.xxx)(PORT=1521)))(CONNECT_DATA=(SID=W245Q)(SERVER=DEDICATED)));User Id=ah_pvellan;Password=xxxx;”

    set rs= createobject(“adodb.recordset”)
    sql=”select a.IE_message_body,a.REQUEST_TYPE from t_hbs_ie_message a, t_hbs_ie_transaction b where b.confirmation_no =”HAMST_78″”
    msgbox sql
    rs.open sql, dbc_conn,1,3

    const strDirectory = “C:\Documents and Settings\pvellan\Messages\”

    Do until rs.EOF
    If Not IsNull(rs!REQUEST_TYPE) Then
    strFileName= strDirectory&rs.Fields(“REQUEST_TYPE”)&”.”&xml
    End If

    writeBinaryFile rs.Fields(“IE_MESSAGE_BODY”).value,strFileName
    rs.MoveNext

    Loop

    When i try excecuting the above code, i get VB compilation error.End of statement expected “)”

    Can you help me out with this?

    Thanks,
    Lisa

    Comment by Lisa | July 4, 2009 | Reply

  251. This website is very helpful as Im new into this.Good source of informations.Will add to my RSS feed.
    Thans.
    jean

    Comment by jean jameson | July 7, 2009 | Reply

  252. Thanks for sharing informations.Looking forward to more stuff.

    Comment by john daily | July 10, 2009 | Reply

  253. I appreciate when people enjoy sharing knowledge .Thanks for informations

    Comment by Mark Kinch | July 11, 2009 | Reply

  254. Hi Suresh,
    i am trying invoke QTP from vb script under automation object model and load libraries with Executefile “path of the .vbs file”
    the problem is i am getting an error
    —————————
    Windows Script Host
    —————————
    Script: C:\QTPWeb\QTP_settings_v1.00.vbs
    Line: 64
    Char: 3
    Error: Type mismatch: ‘ExecuteFile’
    Code: 800A000D
    Source: Microsoft VBScript runtime error

    —————————
    OK
    —————————
    please let me what is the solution for this issue.

    Comment by Tejaswi | July 17, 2009 | Reply

  255. Hi, Can you help me, i’m trying to select one column in teh Data Table of the action2, delete the current values and paste in the same column new values (from clipboard). How to write this in the action1 code? Thanks,Claudia Warsz

    Comment by Claudia Warsz | July 22, 2009 | Reply

  256. Hi Mohan…:)
    hope thingz sailing @ u side great na,
    thz iz sudheer,
    i’ve been involved @ QTP from past 1yr,
    think so u’ve awesome scripting knowledge @ QTP,
    i’ve read all u r scriptz,
    thoz r very nice,
    can i ask u r help if i get any doubt @ QTP,
    may i’ve u r mail id plz,
    if u don mind,
    thank u very much,
    have a great n cheerful time ahead…:)

    Comment by SUDHEER | July 22, 2009 | Reply

  257. Hai Mohan

    I visited u r blog, happy to get help from it.

    I need a script how to select a particular item from ActiveX combo box?

    Comment by Veerendra | July 23, 2009 | Reply

  258. Hi Mohan,
    I am automating windows application which was developed on >NET framework . So i use .NET, ActiveX and windows add ins. The left navigation of my application is recorded as a single winobject. When i click on any item in the navigation tree, it is recorded with specific to the ordinates. This is a problem as it becomes machine dependent (resolution dependant and depends on settings).
    Could you please suggest me how to resolve this problem so that the navigation is generalised.

    Comment by cherla | July 24, 2009 | Reply

  259. Hey mohan,
    Nice work ! very few people will do this kind of job Am also qtp expert but don’t have patience to read and answer the queries really great work .
    regards,
    romy.

    Comment by Romia | July 27, 2009 | Reply

  260. Hi Mohan,
    I’ve been given the task to explore the best way to generate QTP10 tests from within another application (a test script generator generates test scripts which should then be exported in QTP10 format and later executed with QTP10).
    I’ve been unsuccessfully searching the web for a QTP10 test file format specification.
    I’ve skimmed the QuickTest automation object model help file and some web entries about it but I’m still not sure if it can be used for that or just for “configuring QTP options and running tests”.
    Could you please help me with info about:
    1. Can a QTP10 test files format be found on the web and where (to solve it with a converter)?
    2. Can QTP QuickTest automation object model be used to create complete tests?
    3. If both ways are possible, what do you think which way would be better/easier?
    This info would be a lifesaver for me since I have to report my findings tomorrow (Wednesday), perhaps prolong it to Thursday.
    Thx
    Zdenko Blazevic

    Comment by Zdenko Blazevic | July 28, 2009 | Reply

  261. Hi,

    I have provided the password as “mercury” in the Flights application.I encrypted it using the Password Encryption tool that comes with QTP.
    Now when I am reading the properties of the Password textbox I see that the value for the property “Text” for this Password editbox is empty!And in no other property is the textvalue shown.How to fetch the value/text from a edit box when the text is in encrypted format?
    Please help.
    Many Thanks!

    Comment by Renu | July 30, 2009 | Reply

  262. This is actually some Very nice information. Thanks for this.

    Comment by Teresa James | July 30, 2009 | Reply

  263. A good post, thanks for sharing this stuff.

    Comment by Mike darley | August 9, 2009 | Reply

  264. Hi,

    I like to implement QTP in my application . I need Installation document and QTP implementation for the analysis . Could you send me those docs to me?

    Thanks In Advance

    Thanks,
    Mohan Kumar

    Comment by Mohan | August 13, 2009 | Reply

  265. Hi Mohan,

    Really good going, thanks for these informations.

    I am finding some problems with WebElement in QTP (Not using Descriptive Programming in my scripting)

    There will be a Link after clicking that the WebElement displays as “This is 28 Day View” again if i click the same Link it displays as “This is 14 Day View”

    Now i have used Regular Expression as “This is\. .*” for the innertext at WebElement in Object Repository

    If i Run the script it Displayed the Error saying like Object repository not found.

    Can you please help me on this. Thanks in Advance

    Regards,
    Suresh

    Comment by Suresh | August 27, 2009 | Reply

  266. I am a starter in QTP. have u got any information about GUI regression testing

    Comment by eash chand | August 30, 2009 | Reply

  267. Hi mohan,

    You are doing woderful service to the testing industry.
    I generally visit your site for any solutions.

    Good Work.

    Regards
    Subu

    Comment by Subu | September 4, 2009 | Reply

  268. Hi Mohan,

    Nice work. It really helped me a lot. Thanks a lot.
    Expecting to see more in future.

    Thank you,

    Comment by Mallesh | September 8, 2009 | Reply

  269. Hi Mohan,

    Can you just tell me the procedure to get the row ID of a particular row using QTP.

    To be more clear if the rowid of a column is 45.How can i get that number using QTP?

    Comment by Bobby | September 9, 2009 | Reply

    • scenario: Need to run a test script on 5000 machines, its kinda regression testing.
      The 5000 workstations are located in different cities but are all in the same domain and are accessible remotely via RDP.
      All the workstations have QTP installed on them. LoginId has admin rights to all the machines.
      Have installed QC Remote Agent, QC QTP Addin on all the workstations.
      Wondering if I can use QC to run the scripts remotely on these machines.
      But the issue was how to add the 5000 hosts(ip addresses) dynamically in the QC to invoke QTP scripts on other machines after completing on one machine.
      Is it possible to use tables of QC, how do I use the OTA API here, as I’m new using that.
      Kumar
      6128172620

      Comment by Kumar | October 15, 2009 | Reply

  270. Just to make you aware:
    The development of the Phoenix AZ region, has inspired the construction of homes, estates and businesses; and unintentionally created an oasis for pests. Readily available food and water, contribute to the growth, development and spread of Phoenix pest control problems. As a result, the proliferation of Phoenix pest control problems like the Fire Ant, Scorpion and Black Widow Spider; have caused more damage to real estate in the United States, than fires and storms combined.

    Comment by Phoenix Pest Control | September 16, 2009 | Reply

  271. Hi Mohan,

    Gud work………….

    Is there any alternative way for Recovery Scenario except if…else

    Thx
    Sailu

    Comment by Sailaja | September 22, 2009 | Reply

  272. Hi Mohan,

    can you tell me how to capture the secure code on a website and code it using the VBScript in QTP. Below is the site I am using to send free sms.
    http://www.text4free.net/

    Thank You,
    Padma

    Comment by Padma | September 25, 2009 | Reply

  273. Hi mohan,

    I saw in your web site about merging two excel document,

    Can you provide a code to merge two or more Msword that has screenshot and Text in both documents and merge into one single document.

    Thanks,VVs

    Comment by vvr | October 3, 2009 | Reply

  274. Hi mohan,

    I need a qtp script to merge 2 or more word documents into one document.

    each word document has text and screenshot in it.

    can you please send the script ?

    Thanks,
    vishal

    Comment by vishal | October 3, 2009 | Reply

  275. I need a script to add headers and footers in word document.

    can somebody reply ASAP

    Thanks,

    Comment by vishal | October 3, 2009 | Reply

  276. Hi Mohan,

    Can you post the qtp script to insert header and footer in the msword doc?

    Comment by vvr | October 7, 2009 | Reply

  277. Hi,

    I saw ur bolg today first time, it is awsome…
    I need one favor from u.
    I have start Run scripts from QC automatically, when i received a email. If it is possible please help in this regard..
    thanks advanced

    Regards,
    Ashok

    Comment by ashok | October 8, 2009 | Reply

  278. ABEY! MAAA key LAUDEY! STOP spammin my friends facebook! chutiye! teri gaand maarunga Afghanistan se aa key!

    Haraam khor! 4 goliyaan teri gaand mein daalonga to thujhey paata chalega! Raaaa ke lund

    Comment by sherkhan_theonlyone | October 11, 2009 | Reply

  279. Hi Mohan,

    How to write user defined functions in QTP?i want to know how to create functions right from the scratch.Please help me of how to create user defined functions in easiest and simple way.

    Comment by Revathi | October 14, 2009 | Reply

  280. hi.need help in qtp.i want to learn qtp can u give basic suggestios in this plz.

    Comment by ashok | October 19, 2009 | Reply

  281. hi , i want to learn qtp can u give assistence to me plz sir.

    Comment by ashok | October 19, 2009 | Reply

  282. HI.

    I am unable to view the result window in QTP 10.0 even i have set all the option that are required specially Tool-option-run, but window does not appear at end of session. I can not even open the window when i click the result icon on the screen. Please help me out. Your early response will be highly appreciated.

    Comment by Khisal | October 20, 2009 | Reply

  283. Hello Mohan,

    Can you please help\guide me for an QTP script which creates User in Test Director (Quality Center).

    Regards
    Tahir Naim

    Comment by Tahir | October 21, 2009 | Reply

  284. Hi Mohan,
    We have a requirement where we have to test a report which is a PDF. There is some static and dynamic text in that report. The static text depends on employee data for ex. name and his stats etc is dynamic where rest of the text is static.

    There are almost 16 pages of report out of which 10-30 words will be dynamic (which are taken from DB).

    Can you please suggest how to test this and also the best tool to automate this? QTP???

    Thanks in advance!

    Comment by Sravanthi | October 24, 2009 | Reply

  285. Hi All,
    We have a requirement where we have to test a report which is a PDF. There is some static and dynamic text in that report. The static text depends on employee data for ex. name and his stats etc is dynamic where rest of the text is static.

    There are almost 16 pages of report out of which 10-30 words will be dynamic (which will be fetched by DB)

    Can you please suggest how to test this and also the best tool to automate this?

    Thanks in advance!

    Comment by Sravanthi | October 24, 2009 | Reply

  286. Great information and great site, I have added this to my favorites, do you have an rss feed I can subscribe too?

    Comment by Internet Search | November 4, 2009 | Reply

  287. Hi Mohan,

    Ours is a 64 bit application and it is written in MFC (VC++) can we automate this aplication using QTP? QTP 10 version is recognizing these objects as winobjects is there any work around of how to automate this application?
    Its in a medical domain…

    Comment by Varsha | November 6, 2009 | Reply

  288. We have a desktop app we’d like to use automated testing on & wondering if QTP 10.0 supports it – it is a C++/MFC desktop app that uses QT UI Framework ? If not, are there any options with say QTP extensibility? And it is a 64 bit application.

    Comment by Varsha | November 6, 2009 | Reply

  289. Hi Mohan,
    How I can handle the dynamic download dialog box in QTP and wait till the file get downloaded?
    Scenarios is:
    1) Open a browser
    2) Click on download link
    3) Prompt for Save the file,click on Save button
    4) Set the location and click on save
    5) A Window comes with progress bar names as “1% of file name”
    6) I want that QTP will wait until the file get downloaded
    It works for one file, but when I want to downlaod another file with same script without modification I can’t do so
    because name file name is changed ion the dialog box
    What I can do that it can work for more than 2 files

    Thanks,
    Pawan

    Comment by Pawan | November 9, 2009 | Reply

  290. Hi Mohan,
    How I can handle the dynamic download dialog box in QTP and wait till the file get downloaded?
    Scenarios is:
    1) Open any web browser
    2) Click on any download link
    3) Prompt for Save the file,click on Save button
    4) Set the location and click on save
    5) A Window comes with progress bar names as “1% of file name”
    6) I want that QTP will wait until the file get downloaded
    It works for one file, but when I want to downlaod another file with same script without modification I can’t do so
    because name file name is changed ion the dialog box
    What I can do that it can work for more than 2 files

    Thanks,
    Pawan

    Comment by Pawan | November 9, 2009 | Reply

  291. Dear,

    I am not able to open my Yahoo mail ID. As it seems that i have forgotten my Password. Plus i am not able to retrive the say through security questions
    Please help me .

    Comment by Priti Khurana | November 20, 2009 | Reply


Leave a comment