Step 1: Create a New Action or Function<\/strong><\/p>\n\n\n\nOpen a test and insert a new action, or open a new function library and create a new function called SetVariables.<\/p>\n\n\n\n
If you are working in the Expert View, then follow Step 4 directly. If you are working in a function library, continue with Step 2 and Step 3.<\/p>\n\n\n\n
Step 2: (For Function Libraries Only) Associate the Function Library with a Test<\/strong><\/p>\n\n\n\nMake sure the function library is in focus. Select File > Associate Library \u2018<Function Library Name>\u2019 with \u2018<Test Name>\u2019. QuickTest associates the function library with your test.<\/p>\n\n\n\n
Step 3: (For Function Libraries Only) Add a Call to the Function in Your Test<\/strong><\/p>\n\n\n\nAdd a call to the function by inserting a new step and typing the following in the Expert View: SetVariables.<\/p>\n\n\n\n
Step 4: Add Breakpoints<\/strong><\/p>\n\n\n\nAdd breakpoints at the appropriate lines.<\/p>\n\n\n\n
Step 5: Begin Running the Test<\/strong><\/p>\n\n\n\nRun the test. The test or function library stops at the first breakpoint, before executing that step (line of script).<\/p>\n\n\n\n
Step 6: Check the Value of the Variables in the Debug Viewer Pane<\/strong><\/p>\n\n\n\nStep 7: Check the Value of the Variables at the Next Breakpoint<\/strong><\/p>\n\n\n\nClick the Run button to continue running the test. The test stops at the next breakpoint.<\/p>\n\n\n\n
Step 8: Modify the Value of a Variable Using the Variables Tab<\/strong><\/p>\n\n\n\nStep 9: Modify the Value of a Variable Using the Command Tab<\/strong><\/p>\n\n\n\nStep 10: Repeat a Command from the Command History<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"Suppose you create an action or a function that defines variables that will be used in other parts of your test or function library. You can add breakpoints to the action or function to see how the value of the variables changes as the test or function library runs. To see how the test or […]<\/p>\n","protected":false},"author":1,"featured_media":248,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[14],"tags":[],"table_tags":[],"class_list":["post-241","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-software-testing-certification"],"yoast_head":"\n
Debugging an Action or a Function in QTP - Software Testing Stuff<\/title>\n \n \n \n \n \n \n \n \n \n \n \n \n \n\t \n\t \n\t \n \n \n \n \n\t \n\t \n\t \n