Loading ...
Sorry, an error occurred while loading the content.

Re: [ydn-javascript] Re: formatting row on the fly

Expand Messages
  • David Fealkoff
    Hi Ryan, thanks for the quick reply.  it worked fine. David ________________________________ From: Ryan V. Bayona To:
    Message 1 of 3 , Jul 31, 2009
    • 0 Attachment
      Hi Ryan,
       
      thanks for the quick reply.  it worked fine.
       
      David


      From: Ryan V.. Bayona <r2b2_ry@...>
      To: ydn-javascript@yahoogroups.com
      Sent: Friday, July 31, 2009 12:28:51 AM
      Subject: [ydn-javascript] Re: formatting row on the fly

       

      --- In ydn-javascript@ yahoogroups. com, "davidfealkoff" <davidfealkoff@ ...> wrote:
      >
      > I've created a table which lists messages. Messages that haven't been read are given a class="unread" which is added via a call to Dom.addClass( elTr, 'unread') in the formatRow function.
      >
      > Upon reading the message, identified in the "rowSelectEvent" , I want to remove the class "unread" without redownloading the table. Unfortunately, I haven't been able to discover how to do this. Is it possible to change the class in this way? If so, can you provide a code snippet which shows how to do this?
      >
      > Thanks.
      > David
      >

      You can do it within the rowSelectEvent too,.

      YourDataTable. subscribe( "rowSelectEvent" , function (args){
      var el = args.el;
      var record = args.record;
      YAHOO.util.Dom. removeClass( el,'unread' );

      });


    Your message has been successfully submitted and would be delivered to recipients shortly.