Solved

Code to deselect first row in list view

  • 16 September 2020
  • 2 replies
  • 4 views

Hi All

 

Wonder if there any code gurus who could help on this request (or tell me if it's possible)

 

I'm using the script at the bottom of this post to automatiaclly select the first row of a list view (which is contained on a form).  This is so I can run the 'on click' event automatically without the user having to do anything.

 
However I'm now after some code to automatically deselect the first row (so a reverse)
 
Can anyone help?
Paul
 
================================================
<script>
$('div[name="PanelTitle"]').find($('td.first'))[0].click();
</script>
================================================
icon

Best answer by Albarghouthy 16 September 2020, 13:31

View original

2 replies

Userlevel 5
Badge +16

Hi,


 


Try this script


<script>
var contentTable = $('.grid').find('.grid-body-content');
$(contentTable).find("tr:eq(0)").removeClass('highlighted selected');
</script>

thanks Mustafa


Your code works perfectly - thanks

Paul

Reply