:: Forum >>

How to change content of a specific column

Hi

I searched the forum for this but was not successful in finding an answer. I want to change the content of a specific column before displaying to the user.
For example, column 7 has numbers but if the number is below 0, I want to change it to display 0 and not -1 or -10 etc..

here is sample code but this doesn't work....any ideas?

obj.getColumnTemplate(7).getContent("value", changeNum);

function change()
{
var value = this.getItemProperty("value");
if (value < 0)
return 0;
else
return value;
}
Jason
Saturday, September 3, 2005
opps..this is what I had

obj.getColumnTemplate(7).setContent("value", changeNum);

..but this doesn't work either
Jason
Saturday, September 3, 2005
Jason,

My guess is that the function does not know what this.getItemProperty is. Try passing this.getItemProperty as a parameter.
Dougie
Monday, September 5, 2005
looks like you are calling changeNum, but your function name is change
Tuesday, October 11, 2005

This topic is archived.


Back to support forum

Forum search