Error during execution of QTP script - Printable Version +- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums) +-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP) +--- Forum: VB Scripting/Descriptive Programming (https://www.learnqtp.com/forums/Forum-VB-Scripting-Descriptive-Programming) +--- Thread: Error during execution of QTP script (/Thread-Error-during-execution-of-QTP-script) |
Error during execution of QTP script - prasadworld321 - 03-12-2010 if an error occur during execution of QTP script, how can i get the name of the current object that causes the error??? RE: Error during execution of QTP script - Ankur - 03-13-2010 It will show up in the results file. In case you want to get the VBS error description you can use err object. RE: Error during execution of QTP script - prasadworld321 - 03-13-2010 thanks RE: Error during execution of QTP script - Vandembergue - 03-29-2010 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 RE: Error during execution of QTP script - jsknight1969 - 03-29-2010 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. RE: Error during execution of QTP script - Vandembergue - 03-30-2010 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. RE: Error during execution of QTP script - Vandembergue - 04-22-2010 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. |