1

Using coded-ui-tests to automate a screen which is using wijmo grid with scroll.

The problem is not able to record all the cells, as the cells which appear after scroll does not render in DOM, this is evident from Inspect element feature of browser.

How can I catch the cells?

Edited: The issue here is that only the cells which are visible is getting rendered in dom as we can see, while the part of the grid which is on right i.e. which will appear after scrolling is not getting rendered.

  • The red line shows only the visible cells are rendered not the ones which are towards right of the grid.
  • The yellow highlighted div shows the start of new row (which should not be in the actual case until all the cells of above row are not rendered).

enter image description here

rp4361
  • 433
  • 1
  • 5
  • 20
  • Can you give a sample of the html for the wijmo? – lloyd Apr 15 '15 at 00:31
  • Possibly [SendKeys](https://msdn.microsoft.com/en-us/library/system.windows.forms.sendkeys.aspx) {UP} {DOWN} {LEFT} {RIGHT} – lloyd Apr 15 '15 at 05:40
  • ok fine, I can do that but then it will capture every up,down,left,right separately, while i need to capture whole row at one go. – rp4361 Apr 15 '15 at 05:53
  • I'm assuming you've already maximized the browser window? – lloyd Apr 16 '15 at 01:41
  • no its 100%, is there any property of wijmo which i can make use of so that it starts showing whole row in dom rather than only the visible part. – rp4361 Apr 16 '15 at 06:43
  • possibly need to run some [jQuery](http://stackoverflow.com/questions/3235013/how-to-use-jquery-in-selenium) to show the whole row by changing width and height – lloyd Apr 16 '15 at 07:15
  • ok lloydm, as far as i know we can use codedui.jqueryextentions and then we can use like **EnableScript()** method...can you further explain memore about it. Can i alter browser zoom anyhow ? – rp4361 Apr 17 '15 at 07:08
  • The best way is to try [jQuery](http://try.jquery.com/). altering the browser zoom will typically fail the coded ui test in error. $( ".wj-cell" ).css( "width: 1", "height: 1" ); – lloyd Apr 18 '15 at 09:46
  • ok, but bow iam able to get all the values in zooming in to an extent from where no scrolls are there....but that is happening in ie11 – rp4361 Apr 18 '15 at 09:49
  • Wijmo Flexgrid has inbuilt virtualizatio and therefore, only visible cells are rendered in the DOM. This is the design behavior of the control in order to provide good performance. Else, if there are 10000 records in the grid and each is rendered then it would take a lot of time. You can display all the records by not setting the height of FlexGrid. – Ashish Apr 27 '15 at 11:53
  • yeah that is why it doesn't render all the columns at once.Thanks. I did a workaround for getting all column rendered. – rp4361 May 05 '15 at 07:22

1 Answers1

1

For record, Wijmo Flexgrid has inbuilt virtualizatio and therefore, only visible cells are rendered in the DOM. This is the design behavior of the control in order to provide good performance. Else, if there are 10000 records in the grid and each is rendered then it would take a lot of time. You can display all the records by not setting the height of FlexGrid.

Ashish
  • 594
  • 1
  • 6
  • 12