CWRodgers
14 years agoOccasional Contributor
Telerik Grid Control Question
We use the Telerik controls throughout our software products and with the 8.5 release of Test Complete I have enjoyed the ease of use. However, we have a new grid that we are using that is causing problems as far as being able to click on a cell to activate that row in the grid. I am able to use the wValue method to grab the value of a field to ensure the field has the desired value but when I try to invoke the ClickCell action I get an error message and the system halts testing. I cannot tell what I am doing wrong or if this is even correct after looking through all the help files. Any help that you guys can give would be appreciated.
I have written a simplified bit of script to demonstrate what I am doing throughout with the wValue and ClickCell actions. Does this work? AM I using i correctly (I thought I was)?
Sample code:
<snip>
function Test11()
{
var TextMessage;
var RadGridView;
RadGridView = Aliases.SNCDosimetry.frm_MainForm.pnl_MainWork.doccon_MainWork.dt_MainWork.Imported.ScanOutputUserControl.m_dock.radSplitContainer1.m_tsDetails.m_twDetails.m_grd;
TextMessage = (RadGridView.wValue(0, "Type"));
Log.Message(TextMessage);
RadGridView.ClickCell(0, "Type");
}
</snip>
The log message will add the field value to the log file and it is correct. But the next line causes the following error to be added to log file ...
An error occurred.
Then if you click on the Additional Information tab you will see the following:
Possible reasons:
1. The application stopped responding.
2. The
application was compiled incorrectly (see the Open Applications topic in the
help system).
3. An error occurred in TestComplete.
Technical
information:
103 0x80020006 (Unknown name.) CellElement.
Tested
object:
Aliases.SNCDosimetry.frm_MainForm.pnl_MainWork.doccon_MainWork.dt_MainWork.Imported.ScanOutputUserControl.m_dock.radSplitContainer1.m_tsDetails.m_twDetails.m_grd
(Sys.Process("SNCDosimetry").WinFormsObject("frmMainForm").WinFormsObject("m_dock").WinFormsObject("documentContainer1").WinFormsObject("m_dtMain").WinFormsObject("Imported").WinFormsObject("ScanOutputUserControl").WinFormsObject("m_dock").WinFormsObject("radSplitContainer1").WinFormsObject("m_tsDetails").WinFormsObject("m_twDetails").WinFormsObject("m_grd"))
I have written a simplified bit of script to demonstrate what I am doing throughout with the wValue and ClickCell actions. Does this work? AM I using i correctly (I thought I was)?
Sample code:
<snip>
function Test11()
{
var TextMessage;
var RadGridView;
RadGridView = Aliases.SNCDosimetry.frm_MainForm.pnl_MainWork.doccon_MainWork.dt_MainWork.Imported.ScanOutputUserControl.m_dock.radSplitContainer1.m_tsDetails.m_twDetails.m_grd;
TextMessage = (RadGridView.wValue(0, "Type"));
Log.Message(TextMessage);
RadGridView.ClickCell(0, "Type");
}
</snip>
The log message will add the field value to the log file and it is correct. But the next line causes the following error to be added to log file ...
An error occurred.
Then if you click on the Additional Information tab you will see the following:
Possible reasons:
1. The application stopped responding.
2. The
application was compiled incorrectly (see the Open Applications topic in the
help system).
3. An error occurred in TestComplete.
Technical
information:
103 0x80020006 (Unknown name.) CellElement.
Tested
object:
Aliases.SNCDosimetry.frm_MainForm.pnl_MainWork.doccon_MainWork.dt_MainWork.Imported.ScanOutputUserControl.m_dock.radSplitContainer1.m_tsDetails.m_twDetails.m_grd
(Sys.Process("SNCDosimetry").WinFormsObject("frmMainForm").WinFormsObject("m_dock").WinFormsObject("documentContainer1").WinFormsObject("m_dtMain").WinFormsObject("Imported").WinFormsObject("ScanOutputUserControl").WinFormsObject("m_dock").WinFormsObject("radSplitContainer1").WinFormsObject("m_tsDetails").WinFormsObject("m_twDetails").WinFormsObject("m_grd"))