Jump to content

Changing background color of a text area in Spotfire TIBCO at runtime


Ramya Sk

Recommended Posts

I want to change background color of a table in text area using the property defined. That is the property value will change at runtime. Everytime when the text area is refreshed it should have the latest background color for the table
Link to comment
Share on other sites

var list1=["a","b","c"]

var list2=["d","e"]

 

var tableid= document.getElementById('tableid');

var name= document.getElementById('name'+).textContent;

if(list1.indexOf(String(name).trim())>-1)

{

if(tableid !=null)

{

tableid.style="color: ADFF2F; background-color:ADFF2F"

}

}

else if(list2.indexOf(String(name).trim())>-1)

{

if(tableid !=null)

{

tableid.style="color: #DAA520; background-color:#DAA520"

}

}

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...