I am Testing WPF Application using Coded UI.. My testcase is like verifying whether button is enabled or not. wpf button is present in wpftcell which is in the wpftable.
public void verifyInstall_uninstallButton()
{
ResultsPageClasses.ResultsPage Objresultpage = new ResultsPageClasses.ResultsPage();
WpfButton btninstall = Objresultpage.UISalesforceConnectorVWindow.UIItemTable.UIItemDataItem.UIItemCell.UIInstallButton;
WpfButton btnunInstall = Objresultpage.UISalesforceConnectorVWindow.UIItemTable.UIItemDataItem.UIItemCell.UIUninstallButton;
WpfCell cell = Objresultpage.UISalesforceConnectorVWindow.UIItemTable.UIItemDataItem.UIItemCell;
WpfTable table=Objresultpage.UISalesforceConnectorVWindow.UIItemTable;
WpfControl dataitem = Objresultpage.UISalesforceConnectorVWindow.UIItemTable.UIItemDataItem;
if(btnunInstall.Enabled)
{
Console.Write("pass");
}}
When I run this My test is getting fail following error is displayed
System.ArgumentException: No row was specified as search container for the control. To search for a cell control using 'ColumnIndex', you must specify row as a container element or add 'RowIndex' to the search property of the cell. Parameter name: SearchProperties
I am Using visula studio premium update 2 2012
Can any help me to solve this
Thanks