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

DataTable -- Need Text and Value field.

Expand Messages
  • soulrevanger
    Hi, I am facing new problem in DataTable. I have colum whose formatter is DropDown. It is the known fact that dropdown control having text and value
    Message 1 of 4 , Sep 29 3:11 AM
    • 0 Attachment
      Hi,
      I am facing new problem in DataTable. I have colum whose formatter
      is DropDown.
      It is the known fact that dropdown control having text and value
      properties.
      Assume my dropdown contains the following fields

      Value Text
      {"1","One"}
      {"2","Two"}
      {"3", "Three"}

      I have placed this dropdown inside my DataTable cell formatter. It is
      working very fine. But I am having the following problem.
      When I changed the dropdown values, assume I change the value from
      "one" to "Three". This time cell text should display as "Three", But
      instead of this cell text display as "3". It gets the Value field
      only. In my scenario, The Text fields should be displayed inside the
      cell while I need to fetch the corresponding value field for this
      selected cell. How can I achieve this?

      Thanks in Advance.

      Regard
      A AntonySP
    • Satyam
      There is something that I don t understand. If you use the dropdown formatter as you say below then there is no text field, it is a drowdown all the way. If
      Message 2 of 4 , Sep 29 9:49 AM
      • 0 Attachment
        There is something that I don't understand. If you use the dropdown
        formatter as you say below then there is no text field, it is a drowdown
        all the way. If you are using a dropdown editor (not a formatter) then
        you have to provide the formatter with the same dropdown option values.
        There is no correspondence in between the dropdown formatter and the
        dropdown editor. I guess that what you are using is the dropdown editor
        and then want the text reflected on the cell based on the value. If
        that is so, you will have to make your own formatter. If you can
        further clarify what is the case, I (or anyone else) can help you with
        either.

        Satyam


        soulrevanger wrote:
        > Hi,
        > I am facing new problem in DataTable. I have colum whose formatter
        > is DropDown.
        > It is the known fact that dropdown control having text and value
        > properties.
        > Assume my dropdown contains the following fields
        >
        > Value Text
        > {"1","One"}
        > {"2","Two"}
        > {"3", "Three"}
        >
        > I have placed this dropdown inside my DataTable cell formatter. It is
        > working very fine. But I am having the following problem.
        > When I changed the dropdown values, assume I change the value from
        > "one" to "Three". This time cell text should display as "Three", But
        > instead of this cell text display as "3". It gets the Value field
        > only. In my scenario, The Text fields should be displayed inside the
        > cell while I need to fetch the corresponding value field for this
        > selected cell. How can I achieve this?
        >
        > Thanks in Advance.
        >
        > Regard
        > A AntonySP
        >
        >
        > ------------------------------------
        >
        > Yahoo! Groups Links
        >
        >
        >
        > ------------------------------------------------------------------------
        >
        >
        > No virus found in this incoming message.
        > Checked by AVG - http://www.avg.com
        > Version: 8.0.169 / Virus Database: 270.7.5/1696 - Release Date: 28/09/2008 13:30
        >
        >
      • deepeyes2c
        Could you post at least a bit of your code or an example page, it would help to get your problem fixed ;)
        Message 3 of 4 , Oct 1, 2008
        • 0 Attachment
          Could you post at least a bit of your code or an example page, it
          would help to get your problem fixed ;)
          --- In ydn-javascript@yahoogroups.com, "soulrevanger"
          <soulrevanger@...> wrote:
          >
          > Hi,
          > I am facing new problem in DataTable. I have colum whose formatter
          > is DropDown.
          > It is the known fact that dropdown control having text and value
          > properties.
          > Assume my dropdown contains the following fields
          >
          > Value Text
          > {"1","One"}
          > {"2","Two"}
          > {"3", "Three"}
          >
          > I have placed this dropdown inside my DataTable cell formatter. It is
          > working very fine. But I am having the following problem.
          > When I changed the dropdown values, assume I change the value from
          > "one" to "Three". This time cell text should display as "Three", But
          > instead of this cell text display as "3". It gets the Value field
          > only. In my scenario, The Text fields should be displayed inside the
          > cell while I need to fetch the corresponding value field for this
          > selected cell. How can I achieve this?
          >
          > Thanks in Advance.
          >
          > Regard
          > A AntonySP
          >
        • Satyam
          I could, but it would be nicer if, after I took the time to explain a few things, you took the time to reply. You want code? There you have it. It isn t
          Message 4 of 4 , Oct 1, 2008
          • 0 Attachment
            I could, but it would be nicer if, after I took the time to explain a
            few things, you took the time to reply. You want code? There you have
            it. It isn't what you want? So sorry.

            http://www.satyam.com.ar/yui/2.5.0/assortedControls.html

            Satyam

            deepeyes2c wrote:
            > Could you post at least a bit of your code or an example page, it
            > would help to get your problem fixed ;)
            > --- In ydn-javascript@yahoogroups.com, "soulrevanger"
            > <soulrevanger@...> wrote:
            >
            >> Hi,
            >> I am facing new problem in DataTable. I have colum whose formatter
            >> is DropDown.
            >> It is the known fact that dropdown control having text and value
            >> properties.
            >> Assume my dropdown contains the following fields
            >>
            >> Value Text
            >> {"1","One"}
            >> {"2","Two"}
            >> {"3", "Three"}
            >>
            >> I have placed this dropdown inside my DataTable cell formatter. It is
            >> working very fine. But I am having the following problem.
            >> When I changed the dropdown values, assume I change the value from
            >> "one" to "Three". This time cell text should display as "Three", But
            >> instead of this cell text display as "3". It gets the Value field
            >> only. In my scenario, The Text fields should be displayed inside the
            >> cell while I need to fetch the corresponding value field for this
            >> selected cell. How can I achieve this?
            >>
            >> Thanks in Advance.
            >>
            >> Regard
            >> A AntonySP
            >>
            >>
            >
            >
            >
            > ------------------------------------
            >
            > Yahoo! Groups Links
            >
            >
            >
            > ------------------------------------------------------------------------
            >
            >
            > No virus found in this incoming message.
            > Checked by AVG - http://www.avg.com
            > Version: 8.0.169 / Virus Database: 270.7.5/1700 - Release Date: 30/09/2008 11:03
            >
            >
          Your message has been successfully submitted and would be delivered to recipients shortly.