SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 7 of 7
  1. #1
    Member
    Join Date
    Apr 2007
    Posts
    92
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    How to put breakpoints in Functions

    Hi
    As per our framework we are not using Actions we are functions concept but debugging time we are getting problems if we are written that scripts in QTP we can use Breakpoint we can watch varibles but if we are using Functions how to solve debug problems .I writeen below functions in a.vbs files
    For Ex:
    public function search1()
    browser("Google").Page("Google").webedit("name:=q" ).set "charvaka"
    'i want break point here
    browser("Google").Page("Google").webbutton("name:= Google Search").click
    end function
    and that functions i excuted in QTP how to put breakpoints in functions
    Executefile "c:\a.vbs"
    search1

    Thanks
    rahul

  2. #2
    Senior Member
    Join Date
    Jun 2007
    Location
    Mumbai, India
    Posts
    265
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to put breakpoints in Functions

    Put breakpoint where function call is given and then use F11 while execution.
    Snehal Pailkar

  3. #3
    Member
    Join Date
    Apr 2007
    Posts
    92
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to put breakpoints in Functions

    Thanks for u r reply
    But i want to debug statements in the functions in QTP interface

  4. #4
    Advanced Member
    Join Date
    Feb 2008
    Location
    Ahmedabad, India
    Posts
    550
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to put breakpoints in Functions

    [ QUOTE ]
    Thanks for u r reply
    But i want to debug statements in the functions in QTP interface

    [/ QUOTE ]
    does that mean you want to see which function qtp is using while debugging???
    If so it's not possible. It's paid software and i don't think they can allow you to see their code/library via debug.

    If not and you just want to put the breakpoint on some line inside the function. Just navigate to the function and press the F9 Key. That's it..
    GauranG Shah
    I don't make the software, Rather I make it better.
    My Blogs:
    All About Automation
    Spell Checker

  5. #5
    Senior Member
    Join Date
    Jun 2007
    Location
    Mumbai, India
    Posts
    265
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to put breakpoints in Functions

    I am assuming that you want to debug statements written inside the functions.

    Now as I said earlier, place breakpoint where you are calling the function. During execution if you use F10, then QTP will execute entire function at one go whereas if you use F11 then QTP will execute all the statements within functions one by one.
    Snehal Pailkar

  6. #6
    SQA Knight
    Join Date
    Jul 1999
    Location
    Grand Rapids, MI
    Posts
    3,727
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to put breakpoints in Functions

    Not sure this is your issue, but:

    You can only used the QTP debugger to debug libs that are included via the Test Settings Resource tab. This is a known "characteristic" in QTP 9. (And this level of debugger support is not even present in QTP 8). So if you are using the QTP ExecuteFile() function you won't be able to debug fuctions included using that mechanism.

  7. #7
    Member
    Join Date
    May 2004
    Posts
    355
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to put breakpoints in Functions

    Another way which I generally use:
    If I have to debug the function, I copy paste that function in my calling script directly and will debug.

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.36 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 10.00%
vBulletin Optimisation provided by vB Optimise v2.6.4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.2.8 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 06:06 AM.

Copyright BetaSoft Inc.