Announcement

Collapse
No announcement yet.

What does "index" in setBarBgColor do?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • What does "index" in setBarBgColor do?

    After spending 1/2 hour fiddling I figured out that in the code below, the parameter "index" must have one of the values 0,1,2. It does not seem to matter which value is used where. Any value > 2 causes the statement to not display. This is true whether there is one, two or three color statements.

    What is that parameter for?

    If the yMin and yMax values are used, the index must be there or a syntax error occurs.

    //test bar color deal
    if (DIOscState == DIOscIN) {
    setBarBgColor (Color.green,0,20,30);
    }
    if (DIOscState == DIOscOUT) {
    setBarBgColor (Color.lightgrey,0,10,20);
    }
    if (DIOscState == DIOscBET) {
    setBarBgColor (Color.lime,0,5,10);
    }

  • #2
    In forum post at: http://forum.esignalcentral.com/show...407#post126407 I addressed this issue and asked that the Glossary be updated to include all parameters. Sadly it seems to have been ignored.

    ------------
    setBarBgColor(Color, Index, low offset, high offset)
    ------------

    The Index refers to the series in the return statement. Number 0 is the the first item in the return statement, 1 is the second, etc. If your return statement only has 3 items then you can only use 0, 1, or 2 as Index in the setBarBgColor() statement.
    Last edited by waynecd; 07-26-2009, 10:25 AM.

    Comment


    • #3
      waynecd
      FYI the articles in the EFS KnowledgeBase for the setBarBgColor() and setDefaultBarBgColor() functions do include all the parameters.(see the links to the corresponding articles that were updated in 2006)
      Alex


      Originally posted by waynecd
      In forum post at: http://forum.esignalcentral.com/show...407#post126407 I addressed this issue and asked that the Glossary be updated to include all parameters. Sadly it seems to have been ignored.

      ------------
      setBarBgColor(Color, Index, low offset, high offset)
      ------------

      The Index refers to the series in the return statement. Number 0 is the the first item in the return statement, 1 is the second, etc. If your return statement only has 3 items then you can only use 0, 1, or 2 as series in the setBarBgColor() statement.

      Comment


      • #4
        Thanks Alex,

        I found those just a minute ago. I expected the -Glossary- to be the place to go for current definitions and the -Search- for examples etc.

        Maybe if eSignal put a statement in the Glossary page that referred users to do a search of the knowledgebase for more up-to-date definitions and examples.

        Just trying to help since I think folks may expect the Glossary to be the first place to look for updated information.

        Wayne
        Last edited by waynecd; 07-26-2009, 10:38 AM.

        Comment

        Working...
        X