0

Setting a color for a TAB - Ninext

Jacques TUR

I have this on a TAB in Display if:  which works perfectly,

function onUpdate(event : any) do
    {
        caption: "LOCATION NOTES",
        color: "#fcfcfc",
        backgroundColor: "#ff3333",
        tooltip: "Here you can see all notes related for this location only.  📝",
        badge: {
            caption: "",
            color: "#b0c4f7",
            backgroundColor: "#ff3333"
        }
    }
end

The issue is I have just tried to use it on another TAB which results in the new TAB vanishing and the TAB it was working on losing it's defined color.

Any idea where I am going wrong?

I do have different Captions for each TAB

2 replies

null
    • Ninox developper
    • Jacques_TUR
    • 1 yr ago
    • Reported - view

    This code is in the "Display field only, if" trigger. At the end of the code you must put "true" (or other boolean condition) to ensure that the tab will be displayed (line 14) :

    function onUpdate(event : any) do
        {
            caption: "LOCATION NOTES",
            color: "#fcfcfc",
            backgroundColor: "#ff3333",
            tooltip: "Here you can see all notes related for this location only.  📝",
            badge: {
                caption: "",
                color: "#b0c4f7",
                backgroundColor: "#ff3333"
            }
        }
    end;
    true
    
      • Alan_Cooke
      • 1 yr ago
      • Reported - view

      Jacques TUR Jacques TUR All sorted thanks - this was my mistake.

Content aside

  • Status Answered
  • 1 yr agoLast active
  • 2Replies
  • 143Views
  • 2 Following