No matter how I try I always end up with the first item in args.get_item below, in my example below one of the images should be hidden on row 4, but instead it hides it on row 1 no matter what I try, the data_item seem to be correct, item or findelement does not and I´m guessing I´m finding the element to hide in the wrong manner, any tips?
function RowDataBound(sender, args) {var di = args.get_dataItem();var item = args.get_item();var sortUp = item.findElement('btnSortUp')var sortDown = item.findElement('btnSortDown') //var sortUp = $(item).find("btnSortUp"); //var sortDown = $(item).find("btnSortDown");var pos = di.abdp_pos_no; if (pos == 1) { $(sortDown).hide(); } if (pos == 4) { $(sortUp).hide(); }}<telerik:GridTemplateColumn HeaderText="Sort" UniqueName="sort" SortExpression="abdp_pos_no" DataField="ben"> <HeaderStyle HorizontalAlign="Right" /> <ItemStyle HorizontalAlign="Right" /> <ClientItemTemplate> <img id="btnSortUp" src="images/copy.png" data-pos="#=abdp_pos_no #" data-way="-1" style="cursor:pointer;" onclick="reorder(this)"></img> <img id="btnSortDown" src="images/copy.png" data-pos="#=abdp_pos_no #" data-way="+1" style="cursor:pointer;" onclick="reorder(this)"></img> </ClientItemTemplate> </telerik:GridTemplateColumn>