Announcement

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

    #16
    i added dblgrid.enableHilite("0"); this to recognize the hilite....and when i am trying to add sethilites...it is looking for the array of hilites...but here i have just one criteria so no array of hilites....do i have to declare it in array eventhough i have one


    thanks

    Comment


      #17
      It's working finally.....:)


      thanks alot........:)

      Comment


        #18
        Just have a doubt....do we have to declare as an array...even though we have one creteriall
        can't we declare like Hilite hilite = new Hilite();
        hilite.setcreteria(.....)

        other than Hilite[] hilites = new Hilites[]{...
        ....};

        Thanks

        Comment


          #19
          Hi...as i am now able to hilite...and continuing coding for my application. i have a list grid and there are about 5 cols and data from xml file
          so where ever the data for the field is 'pass' it should be green color, 'fail' it should be red color and 'inprogress' it should be in blue color so here is what i am doing...it is working fine...but is there any way to simplify the coding plase let me know

          private static Hilite[] hilites = new Hilite[] {
          new Hilite() {{
          setFieldNames("test1");
          setCriteria(new Criterion("test1",OperatorId.EQUALS, "pass"));
          setTextColor("green");
          setCssText("background-color:#CCFF00");
          setId("0");
          }},
          new Hilite() {{
          setFieldNames("test1");
          setCriteria(new Criterion("test1",OperatorId.EQUALS,"fail"));
          setTextColor("red");
          setCssText("background-color:#FF3333");
          setId("1");
          }},
          new Hilite() {{
          setFieldNames("test1");
          setCriteria(new Criterion("test1",OperatorId.EQUALS,"inprogress"));
          setTextColor("blue");
          setCssText("background-color:#6666FF");
          setId("2");
          }},
          new Hilite() {{
          setFieldNames("test2");
          setCriteria(new Criterion("test2",OperatorId.EQUALS, "pass"));
          setTextColor("green");
          setCssText("background-color:#CCFF00");
          setId("3");
          }},
          new Hilite() {{
          setFieldNames("test2");
          setCriteria(new Criterion("test2",OperatorId.EQUALS,"fail"));
          setTextColor("red");
          setCssText("background-color:#FF3333");
          setId("4");
          }},
          new Hilite() {{
          setFieldNames("test2");
          setCriteria(new Criterion("test2",OperatorId.EQUALS,"inprogress"));
          setTextColor("blue");
          setCssText("background-color:#6666FF");
          setId("5");
          }},
          new Hilite() {{
          setFieldNames("test3");
          setCriteria(new Criterion("test3",OperatorId.EQUALS, "pass"));
          setTextColor("green");
          setCssText("background-color:#CCFF00");
          setId("6");
          }},
          new Hilite() {{
          setFieldNames("test3");
          setCriteria(new Criterion("test3",OperatorId.EQUALS,"fail"));
          setTextColor("red");
          setCssText("background-color:#FF3333");
          setId("7");
          }},
          new Hilite() {{
          setFieldNames("test3");
          setCriteria(new Criterion("test3",OperatorId.EQUALS,"inprogress"));
          setTextColor("blue");
          setCssText("background-color:#6666FF");
          setId("8");
          }},
          new Hilite() {{
          setFieldNames("test4");
          setCriteria(new Criterion("test4",OperatorId.EQUALS, "pass"));
          setTextColor("green");
          setCssText("background-color:#CCFF00");
          setId("9");
          }},
          new Hilite() {{
          setFieldNames("test4");
          setCriteria(new Criterion("test4",OperatorId.EQUALS,"fail"));
          setTextColor("red");
          setCssText("background-color:#FF3333");
          setId("10");
          }},
          new Hilite() {{
          setFieldNames("test4");
          setCriteria(new Criterion("test4",OperatorId.EQUALS,"inprogress"));
          setTextColor("blue");
          setCssText("background-color:#6666FF");
          setId("11");
          }},
          new Hilite() {{
          setFieldNames("test5");
          setCriteria(new Criterion("test5",OperatorId.EQUALS, "pass"));
          setTextColor("green");
          setCssText("background-color:#CCFF00");
          setId("12");
          }},
          new Hilite() {{
          setFieldNames("test5");
          setCriteria(new Criterion("test4",OperatorId.EQUALS,"fail"));
          setTextColor("red");
          setCssText("background-color:#FF3333");
          setId("13");
          }},
          new Hilite() {{
          setFieldNames("test5");
          setCriteria(new Criterion("test5",OperatorId.EQUALS,"inprogress"));
          setTextColor("blue");
          setCssText("background-color:#6666FF");
          setId("14");
          }}

          };


          and here i am adding these Id's to fields

          dsfield[7].setAttribute("_hilite","0");
          dsfield[7].setAttribute("_hilite","1");
          dsfield[7].setAttribute("_hilite","2");
          dsfield[8].setAttribute("_hilite","3");
          dsfield[8].setAttribute("_hilite","4");
          dsfield[8].setAttribute("_hilite","5");
          dsfield[9].setAttribute("_hilite","6");
          dsfield[9].setAttribute("_hilite","7");
          dsfield[9].setAttribute("_hilite","8");
          dsfield[10].setAttribute("_hilite","9");
          dsfield[10].setAttribute("_hilite","10");
          dsfield[10].setAttribute("_hilite","11");
          dsfield[11].setAttribute("_hilite","12");
          dsfield[11].setAttribute("_hilite","13");
          dsfield[11].setAttribute("_hilite","14");

          is this is the only way to do this...sorry for too many questions...

          thanks

          Comment


            #20
            i am facing another problem...

            i have setting groupBy()...dor list grid.. when i run the application...after the module load...if i click on the next group details (by default it is opening first group) the hilite properties are not shown in there...it is only shown for the opened first group...how do i set this hilite to all groups (doesn't matter those are opened or not)

            please help me

            thanks

            Comment


              #21
              Hello Isomorphic.....Can you please look at this problem and let me know why it is showing like that....
              problems is i did set up hilites in array and set that to the listgrid...setHilites()
              i also have groupBy(fields) for the list grid. Also i didn't set up GroupStatOpen(GroupStatOpen.ALL) to the list grid so it is displaying only the first group....everything is working fine so far....after module load when i try to open the remaining records....the hilite property seems not working and records are displaying without any hilite properties.....but when set option GroupStartOpen(GroupStartOpen.ALL) to the ListGrid it is displaying all the hilite properties for all records....is this problem is something to do with my coding...or is it the way the core code....please let me know...thanks

              Comment

              Working...
              X