Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Check box in ListGrid

    Hi,
    I am using smartGWT 2.3, and i need to have checkbox in my listgrid.

    i have implimented it, but all the checkbox's are coming as checked even if the value is false.

    Code:
    <field name="GR_DIS_HALT_KZ_VALUE_CheckBoxValue"	type="boolean"  />
    <field name="GR_DIS_INAK_KZ_VALUE_CheckBoxValue"	type="boolean"   />
    java code is
    Code:
    GR_DIS_INAK_KZ_VALUE_CheckBoxValue = new ListGridField("GR_DIS_INAK_KZ_VALUE_CheckBoxValue"," ",60);
    			GR_DIS_INAK_KZ_VALUE_CheckBoxValue.setType(ListGridFieldType.BOOLEAN);
    from backend java i am passing a boolean variable.

    but the value is false, but checkbox's are coming as checked.

    Please help

    #2
    This is a known issue with 2.3 and was fixed soon after the release. Please pick the latest nightly build, or wait for the 2.4 release.

    Thanks.

    Comment


      #3
      Thanks for the reply.
      where can i get the nightly build
      Thanks
      Last edited by vijayakumar_kb; 16 Dec 2010, 21:53.

      Comment


        #4
        www.smartclient.com/builds

        Comment


          #5
          thanks
          i downloaded the jar file from
          http://www.smartclient.com/builds/SmartGWT/2.x/EnterpriseEval/2010-12-17

          and i replaced smartgwtee.jar file. but having the same error.
          do i need to replace ofther files to.

          in the bean i hardcoded "false" but then also it is coming as checked.

          Comment


            #6
            Make sure you clean your browser cache and and do a clean rebuild your project.

            Comment


              #7
              Thank you all.
              it worked. i rebuild the project.

              Comment


                #8
                I noticed this wasn't working when we moved to 2.3 and now we're on the nightly dated 2011-01-06 and I'm still seeing this issue?

                Comment


                  #9
                  Like the other posters here, you should clear your browser cache and rebuild your project to ensure you don't have staleness somewhere. Use the full set of steps here - don't skip any steps or attempt upgrading by just copying .jars around (this will not work).

                  Comment


                    #10
                    I think I have upgraded successfully going through the steps, I've checked the headers for the various JS files upon startup such as ISC_Core.js etc etc, and they all have the appropriately matching dates with the nightly build that I'm on.

                    This checkbox is only used in the UI and is not persisted in the database.

                    This ListGridField is not defined in my Datasource, is this an issue?

                    Comment


                      #11
                      It depends on how exactly you're providing the data. If you're, for example, providing the value for false as the string "false", from a boolean perspective, all non-empty strings are true. Provide a Boolean instead.

                      If that's not the problem, show the contents of the RPC tab for the server response - this will reveal whether you're providing valid values.

                      Comment


                        #12
                        I am setting both true and false during my onDataArrived() callback like this:
                        Code:
                        listGridRecord.setAttribute("Select", Boolean.TRUE);
                        listGridRecord.setAttribute("Select", Boolean.FALSE);
                        in each case.

                        Comment


                          #13
                          The checkbox is functional for me, when I click on it, the click event will perform like expected, we just don't see the visual check in the box.

                          We have our application skinned if this matters? I searched the logs for 404 missing images and couldn't find one related to this issue?

                          Regular check boxes outside the ListGrid work fine.

                          Comment


                            #14
                            Is it possible in your skinning that you've set the true and false image to the same image?

                            Comment


                              #15
                              The app was skinned quite some time ago, and I haven't made any changed to the skin since doing the 2 upgrades: 1.x -> 2.3 -> 2.4

                              It was working fine when we were on 1.x and it broke when we went to SmartGWT Power 2.3.

                              No skin changes during these upgrades.

                              Comment

                              Working...
                              X