can someone share an example script to change the background color of a panel.

can someone share an example script to change the background color of a panel.

I’m having trouble even identifying the panel via script.

var p = LL.getCurrentDesktop.getContainerById(‘#790001’);

does not work

var p = LL.getCurrentDesktop.getItemByName(‘myPanel’);

does not work

var p = LL.getEvent().getContainer();

does not work.

once I get the panel via code I’m also having trouble accessing the background color property.

Box documentation shows that I would use a string such as:

cn:0xffff0000

but where? example– item.SetBoxBackground(‘cn:0xffff0000’);

does not work. nor anything else I’ve tried.

I’ve found very little documentation about this. Any help would be appreciated.

]]>

5 Commentsto can someone share an example script to change the background color of a panel.

  1. Anonymous says:

    < ![CDATA[

    getContainerById(0x790001) as it needs an int

    ]]>

  2. Anonymous says:

    < ![CDATA[

    Bogdan Tautu thanks! Any suggestion for setting the color of a panel?

    ]]>

  3. Anonymous says:

    < ![CDATA[

    the panel would still fall under the folder (f.box) “category”




    var color = 0xff00ff00; // pure green


    var editor = item.getProperties().edit();


    var box = editor.getBox(“i.box”);



    box.setColor(“c”, “ns”, color); // set background color, for normal and selected states



    box.setColor(“bl,br,bt,bb”, “ns”, color); // set all borders color for normal and selected states.



    editor.getBox(“f.box”).setColor(“c”, “n”, color); // set folder background color



    editor.commit();

    ]]>

  4. Anonymous says:

    < ![CDATA[

    if you search the community for “scripting confuses me” the dev walked me through how to modify an items properties.

    ]]>

  5. Anonymous says:

    < ![CDATA[

    This is a great community. I was able to get both features working with your help. Many more as well. I can’t wait to share a short video of my progress after a few more features.

    ]]>

Leave a Reply

Your email address will not be published. Required fields are marked *