Forum Discussion
the line of code is the same for both errors:
if(grid.Columns.Item(i).Caption == header1) {...}
where grid is a vb constructed grid and header1 is a static string of text.
The test follows a simple loop, open test case, get figures from the grid close the case, move to next test case. I can process multiple test cases before getting the error and there are controls built in to make sure the grid is shown before doing the if statement.
- tristaanogre7 years agoEsteemed Contributor
I have some experience with working with VB grids in an application we test and I've seen that error before... Usually, it's solved by making sure that the grid is fully loaded and, if anything refreshes the grid, actually call a "RefreshMappingInfo" call on the grid's parent.
However, the behavior you've described almost sounds like some sort of memory error, that the VB application is running out of available memory to include the information that TestComplete uses.
Are you keeping the application running between all the test cases or do you close and re-open on each one?
- charles_17 years agoOccasional Contributor
I have a function beofre this one that wont carry on till the grid is loaded, so hopefully it isn't the first suggestion.
I don't close the application each time as it would take up too much test time. The application doesn't take up much memory space but TestExecute 12 does.
- tristaanogre7 years agoEsteemed Contributor
Try, before your call of that If then, to do a RefreshMappingInfo of the parent object of the grid. That might do it.
Related Content
- 2 years ago
- 7 years ago
- 8 years ago
- 6 years ago
Recent Discussions
- 2 days ago
- 2 days ago
- 5 days ago