c# - Hiding repeated rows in telerik RadGrid -


i'm attempting hide duplicate cell values specific columns in telerik radgrid.

i attempted use code below not work. stepping through code debugger, can see appears making right decisions. wondering if method i'm using update cell in incorrect or of i'm missing important step.

private void hidegridduplicates(radgrid radgrid, string[] fieldnames)     {         var hashlastvalues = new hashtable();          foreach (string fieldname in fieldnames)         {              foreach (griddataitem item in radgrid.items)             {                 string currentvalue = item.getdatakeyasstring(fieldname);                  if (hashlastvalues.containskey(fieldname))                     if ((string)hashlastvalues[fieldname] == currentvalue)                         currentvalue = "";                     else                         hashlastvalues[fieldname] = currentvalue;                 else                     hashlastvalues.add(fieldname, currentvalue);                  item[fieldname].text = currentvalue;             }           }      } 

update: should looking for:

select expenseid, claimid, [description],transactiondate (select expenseid, claimid, [description],transactiondate,         row_number() on (partition claimid order expenseid) rn         expense) t         rn = 1; 

i have tested on own test database , think trying achieve. if change "partition claimid" change column need.


Comments

Popular posts from this blog

css - SVG using textPath a symbol not rendering in Firefox -

Java 8 + Maven Javadoc plugin: Error fetching URL -

datatable - Matlab struct computations -