03-12-2010, 11:34 PM
if an error occur during execution of QTP script, how can i get the name of the current object that causes the error???
Error during execution of QTP script
|
03-12-2010, 11:34 PM
if an error occur during execution of QTP script, how can i get the name of the current object that causes the error???
03-13-2010, 02:15 AM
It will show up in the results file. In case you want to get the VBS error description you can use err object.
Want to fast track your QTP/UFT Learning? Join our UFT Training Course
03-13-2010, 12:48 PM
thanks
03-29-2010, 09:04 PM
Hi Ankur,
I found very interesting and helpfull tips here but this time it seems a little bit hard for me to find the answer on my own. My scripts purpose is to fullfill a .xls file (OK/KO) while testing its values with those that appear on a website. I have a "General run error" = 2147467259 when any of these 2 statements are executed : 1) Code: Chaine = cElements(0).GetROProperty("innertext") 2) Code: Chaine = cComps(n).GetROProperty("innertext") The error seems to happen when about 9000 lines from my xls file are processed, which make me think to some kind of overflow/memory error. Could you (or anyone here) help me with this ?? Thanks in advance Alain
03-29-2010, 11:28 PM
I have the same issue with ChildObjects on a web page. In some cases I found this helps:
Code: wElement("class").RegularExpression = "false" It seems some description objects use Regular Expressions to do the search, this turns it off and in the case of using "html tag" it does make the search for ChildObjects quicker and less error prone with there are a large number of objects. However, it will still fail if there are x-thousands of objects. This occurs in QTP 9.5 and 10, so there is a limit to the number of objects it can handle. The only "work around" I can find is: Code: on error resume next The error you are getting is because the variable is null/empty, I think. So you have to handle that and let your code continue. I just record the message and move on letting my devs no I can't test that many objects, usually a table, and they need to break it up if possible, or provide test data that doesn't fail. Hope this helps.
03-30-2010, 02:32 PM
Hi There,
Thank you Mr knight for answering so quickly. I'll try to use your advice and will let you know asap if it has helped me.
04-22-2010, 07:17 PM
Actually, i couldn't get the programm to process more that 15.000 lines from my excel file before it get too slow. I'll have to launch the programm twice. I have far too much objects in my different collections.
|
« Next Oldest | Next Newest »
|
Possibly Related Threads… | |||||
Thread | Author | Replies | Views | Last Post | |
How to catch the script execution when QTP scripts are executed from command line | Sreeni.lutukurthy | 0 | 2,943 |
03-19-2015, 05:55 PM Last Post: Sreeni.lutukurthy |
|
vb script to stop execution of functions if conditions fail | visitjaga | 1 | 7,392 |
12-05-2013, 12:26 AM Last Post: ravi.gajul |
|
.vbs script error when trying to insert a value in a sapguitable | frebuffi | 5 | 6,878 |
07-18-2013, 03:04 PM Last Post: Staff |
|
Speed issues on script execution (First Post) | martinshort | 4 | 3,309 |
07-03-2012, 03:02 PM Last Post: martinshort |
|
Error while creating object using description.create object in VB script | SarodeGirish | 5 | 6,270 |
06-19-2012, 05:30 PM Last Post: ssvali |