-
June 26th, 2008, 09:14 AM
#1
Altering Row Color for Even and Odd Keys
Hi Guys
Is there a way for me to be able to alter a row color of odd and even numbered rows using the DynaMetapushTable?
One of the threads I came across had:
itemUpdate.setRowAttribute("red","","backgroundCol or");
Assuming that this works how would I determine whether the row is an odd or even row or a key is an odd or even key.
Thank you!
- garyj
-
June 27th, 2008, 09:38 AM
#2
hi,
i fear that accomplish such task could be a little bit tricky.
First of all note that the setRowAttribute method does not affect the entire template but affects all lightstreamer's cells inside the template. Btw note that the onChangingValues gives to you a reference to the entire container (ie: the template clone) so that you can do any kind of manipulation on it.
Our library does not give to you the position of a row in the table nor a callback to signal that a row has changed position, so to reach your goal you have to go through a more complicated way.
In example you could store the dom references given by the onChangingValues and change the rows colors on the basis of the data you receive, or you could try even and odd rules as shown here (note that I'm not sure this would work as I have no time to test it at the moment, btw if you can give it a try please let us know your results)
HTH
Similar Threads
-
By hungn in forum Client SDKs
Replies: 8
Last Post: March 25th, 2010, 09:02 AM
-
By Test6405 in forum Client SDKs
Replies: 1
Last Post: November 2nd, 2009, 04:55 PM
-
By tuongkha in forum Client SDKs
Replies: 4
Last Post: March 19th, 2008, 10:10 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
All times are GMT +1. The time now is 03:27 PM.
Bookmarks