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

Re: [ydn-javascript] Clickable Colummns/Links Within DataTable

Expand Messages
  • Satyam
    I m copying the following paragraph from my own reply to a similar message posted yeasterday: You can have more column headers declared than the columns
    Message 1 of 2 , Mar 30, 2007
    • 0 Attachment
      I'm copying the following paragraph from my own reply to a similar message posted yeasterday:
       
      You can have more column headers declared than the columns actually available in the data.  You can declare a formatter function for that extra column which can put anything into the cell (the documentation shows how you can set the elCell.innerHTML of the cell).  This formatter function has access to all the data of all the columns in the record, so you can put whatever information you want in it.   Then you will have to listen to the cell click event which will require you to somehow recognize that the click has been on the cell with the extra button or image.  Since the cell click event does not require anything inside the cell itself, you might just draw something button-like through some CSS formatting.
       
      Satyam
       
      PS: I should have added that the reason to listen to the cell click event is that even if you put an <a> kind of link on the cell contents, it won't be triggered, though it can help with the look of the link item and the href attribute can hold the information you need to process it.   Anyway, processing the cell click event gives you far more flexibility than allowing the <a> link to execute.
       
       
       
      ----- Original Message -----
      From: Doug
      Sent: Friday, March 30, 2007 12:12 AM
      Subject: [ydn-javascript] Clickable Colummns/Links Within DataTable

      Hello all

      I'm wanting a way of having a number of different links/icons/ buttons
      at the end of my table so a user can select multiple operations per
      record.

      For example:

      Name Age Phone Edit Delete CallUser

      You'd be able to click one of the three final columns for various
      action s on the specific user.

      Now I have an idea of how to do it but it seems cumbersome so I was
      hoping someone will know how to help me.

      Look forward to your replies.

      Thank you.

      Doug


      No virus found in this incoming message.
      Checked by AVG Free Edition.
      Version: 7.5.446 / Virus Database: 268.18.22/739 - Release Date: 29/03/2007 13:36
    Your message has been successfully submitted and would be delivered to recipients shortly.