cancel
Showing results for 
Search instead for 
Did you mean: 

Not able to double click on row inside datasetview WPF object in RightNow CX application

Occasional Contributor

Not able to double click on row inside datasetview WPF object in RightNow CX application

Hi Team, 

 

I am trying to work with WPF object in desktop based RightNow CX application. Testcomplete is able to identify the object as WPF ReportDataSetView. Full path is as below.

 

Screenshot of the screen is also attached.

 

Sys.Process("RightNow.CX").WPFObject("HwndSource: CxConsole", "System Integration Testing Two  -  Oracle Service Cloud").WPFObject("CxConsole", "System Integration Testing Two  -  Oracle Service Cloud", 1).WPFObject("AdornerDecorator", "", 1).WPFObject("Grid", "", 1).WPFObject("Border", "", 2).WPFObject("AdornerDecorator", "", 1).WPFObject("ContentPresenter", "", 1).WPFObject("Grid", "", 1).WPFObject("DockPanel", "", 2).WPFObject("Grid", "", 1).WPFObject("ContentPresenter", "", 1).WPFObject("Grid", "", 1).WPFObject("DockPanel", "", 2).WPFObject("Grid", "", 1).WPFObject("ContentPresenter", "", 1).WPFObject("GroupBox", "", 1).WPFObject("WindowFrameContainer").WPFObject("Grid", "", 1).WPFObject("CachedWindowFrame").WPFObject("ContentPresenter", "", 1).WPFObject("AdornerDecorator", "", 1).WPFObject("Grid", "", 1).WPFObject("Grid", "", 1).WPFObject("Grid", "", 2).WPFObject("Grid", "", 1).WPFObject("EditorTabSet").WPFObject("ContentPresenter", "", 5).WPFObject("editorPresenter").WPFObject("ConsoleEditorTabView", "", 1).WPFObject("editorPresenter").WPFObject("ContentPresenter", "", 1).WPFObject("AnalyticsConsoleView", "", 1).WPFObject("Grid", "", 1).WPFObject("CachedAnalyticsView").WPFObject("ContentPresenter", "", 1).WPFObject("ReportView").WPFObject("MainReportGrid").WPFObject("ReportGrid").WPFObject("ReportTabControl").WPFObject("AdornerDecorator", "", 1).WPFObject("ContentPresenter", "", 1).WPFObject("GroupBox", "", 1).WPFObject("WindowFrameContainer").WPFObject("Grid", "", 1).WPFObject("CachedWindowFrame").WPFObject("ContentPresenter", "", 1).WPFObject("ContentPresenter", "", 1).WPFObject("ReportDataSetView")

 

 

I need to double click on desired row from this data set (table) to open the record. But it is not giving me any option to double click on the desired row. I am able to go to individual rows and find the cell values using below path.

 

 

WPFObject("ReportDataSetView").DataContext.DataSetViewModel.Rows.Item(0).Item(2).Text

 

Detail of this ReportDataSetView is below.

 

ClrClassName : ReportDataSetView

ClrFullClassName : RightNow.Presentation.Views.ReportDataSetView

 

Is there a way to double click on the desired row from the table. Screens are attached for reference.

 

Can someone please help.

 

Thanks,

Vikas Kumar

+61-414371592

3 REPLIES 3
Community Hero

Re: Not able to double click on row inside datasetview WPF object in RightNow CX application

Most likely there is not a straight "click row" method or something with the view.  I'm assuming that, if you click on any cell in the row, it will, effectively, double click the whole row.

 

So... what you need to do is write some sort of code that executes a for loop to loop through the rows of the table, searching a particular column and looking for a matching value.  Once you find that row, return the row ID and then use it in some sort of call to <table>.Cell(<foundRowValue>, 1).Click().


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Occasional Contributor

Re: Not able to double click on row inside datasetview WPF object in RightNow CX application

Hi Robert, 

 

Thanks for your reply.

 

I tried your approach but this object does not behave like a table and there is no method to click on individual row.

Click and DbClick methods click on center of the whole grid rather than on any row or cell.

 

Sys.Process("RightNow.CX").............WPFObject("Grid", "", 1).WPFObject("CachedWindowFrame").WPFObject("ContentPresenter", "", 1).WPFObject("ContentPresenter", "", 1).WPFObject("ReportDataSetView") 

 

above is the name of the object. 

 

Using DataContext property, i can get the data from cells. But there is no click or dbclick available on this item object.

WPFObject("ReportDataSetView").DataContext.DataSetViewModel.Rows.Item(0).Item(2)

 

 

 

 

Community Hero

Re: Not able to double click on row inside datasetview WPF object in RightNow CX application

Correct... because there is no "On Screen Object" to correspond with that... what you have found are native properties of the grid and they aren't recognized as "On Screen Objects" so don't have the wrapper actions of "Click" or "DoubleClick".  So, you'll have to find some other means of interacting with the grid.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available