aldebaran
14 years agoOccasional Contributor
Waiting for control
Hi all,
I sometimes get exceptions in script-routines when the real object behind a mapped object is passed as a parameter from a keyword test.
This only happens sometimes, because the object, in this case a .net DataGridView, is not completly finished loading with all it´s columns and rows. In the script it seems as if the projects "auto wait time" has no effect for a gridView´s Column or Row properties ?!
The exception message: Dieser Vorgang wurde wegen Zeitüberschreitung zurückgegeben
Unit: "SetVariables" Line: 8 Column: 6.
I guess in English it woud translate to: "The procedure was terminated due to a timeout Unit: ...."
The script-routine in question works perfect and is used from plenty of other keyword-tests.
Here´tis:
Sub setGridLastRowIndex( GridObj )
Project.Variables.LastGridRowIndex = GridObj.Rows.Count -1
Log.Message("LastGridRowIndex is: " & Project.Variables.LastGridRowIndex)
End Sub
auto wait time is high: 30000 milliseconds
I would like to avoid inserting any extra teststeps or calls to yet another script from the keyword tests that use 'setGridLastRowIndex'
What´s the dos and donts if one wants to avoid absolute waits?
Any suggestions are appreciated.
greets
c.
I sometimes get exceptions in script-routines when the real object behind a mapped object is passed as a parameter from a keyword test.
This only happens sometimes, because the object, in this case a .net DataGridView, is not completly finished loading with all it´s columns and rows. In the script it seems as if the projects "auto wait time" has no effect for a gridView´s Column or Row properties ?!
The exception message: Dieser Vorgang wurde wegen Zeitüberschreitung zurückgegeben
Unit: "SetVariables" Line: 8 Column: 6.
I guess in English it woud translate to: "The procedure was terminated due to a timeout Unit: ...."
The script-routine in question works perfect and is used from plenty of other keyword-tests.
Here´tis:
Sub setGridLastRowIndex( GridObj )
Project.Variables.LastGridRowIndex = GridObj.Rows.Count -1
Log.Message("LastGridRowIndex is: " & Project.Variables.LastGridRowIndex)
End Sub
auto wait time is high: 30000 milliseconds
I would like to avoid inserting any extra teststeps or calls to yet another script from the keyword tests that use 'setGridLastRowIndex'
What´s the dos and donts if one wants to avoid absolute waits?
Any suggestions are appreciated.
greets
c.