| || |
General run error
My automation(QTP11) has been running fine for 1.5 years. I Import a excel datasheet to drive my automation. Lately I run a test OK. Go to rerun the test and I get a general run error
when importing my dataspreadsheet. Close QTP, open QTP and the test runs fine. Re-run the test and the general run error occurs.
Any ideas ?
Thanks in advance
What error code you are getting?
Are you releasing and closing object as well?
In my driver script I set On Error Resume Next and put put err.description in the debug watch and it was just an empty string.
I there a setting in QTP the allows the QTP datatable only to load once ?
I have two licenses, so two QTP environments on one VM system and I log in as the other user and that environment runs fine(same driver script)
Use all DP and Set DP = nothing always used, but the import datasheet is the first line of code
New question... test runs fine the first time, second time runtime error. Dataspreadsheet loaded
GetRowCount = 87
GetCurrentRow = 0
First time run GetCurrentRow = 1
Why on the second run of the script does GetCurrentRow return 0 ????
Thx in advance
Did you always use two environments? Is it the new VM system causing the issue?
What does DP = Nothing mean?
Can you put in a .setCurrentRow(1) in the scirpt so you know which row the script will start on?
Running two environments for months
Should have been more clear, I use DP for descriptive programming. When you use descriptive programming you create and object(bypass the OR) and when you
are done with the object you de-associate it from memory by Set DPobject = Nothing
I can try setCurrentRow, but still would like to know why GetCurrentRow fails on second test run.
If it's running fine on another machine, I would just do a clean uninstall then reinstall qtp. At my past job which included maintaining a large test lab, that was a fairly regular occurrence due to corrupted installs. Or since it's a VM just recreate it.
Last edited by NoUse4aName; 06-19-2013 at 06:20 AM.
Unexpected file format error (similar, but different compare to previous)
I use QTP 11 for 2 years under windows XP and have a bunch good working tests. Now I install QTP11 on another PC windows 7. After installation my first action was open tests and I've got error "Unexpected file format" and no one action was loaded to QTP. Functional (very big!) library loaded well, even I did not correct library code yet for windows 7 there. I installed new qtp11.5, then repeated both installs on another PC. Results were always with this error. I login and installed QTP always as admin all over. It's a lot of memory on all PC. It was disabled add-ons and antivirus. Search on this forum brings nothing. Search on Google brings a lot of same complaints, but no positive suggestions. I verified again on XP machine and all tests loaded and run without errors. Any ideas are welcome. Please help. Best regards.
One thing that came to mind is to delete all temp files. Perhaps you have done this already, if not, it's worth a shot.
Patience is like bread I say.... I ran out of that yesterday.
I've had issues with datatable loading.
getCurrentRow() usually returns 1 when the script starts up (as I expect) but occasionally it returns 0. This was causing errors, but I can no longer remember if it caused a 'General Run Error' or a more specific DataTable.ImportSheet(...) problem.
To work around this I use the following code at the top of all my scripts that load external spreadsheets:
Where StartUp() is a function that handles application and script initialisation, including loading of the datatable.
If DataTable.GetSheet("Action1").GetCurrentRow < 2 Then StartUp(...)
It's something else to look into anyway.
... just another Tester ...