I tried this... but it gave me an error.
document["lyr"].layer-background-color = "red";
The dashes in the layer-background-color property causes error in Netscape.
Can someone please help me, Thanks.
I have tried to change layer properties too, but to no avail. This is particularly problematic when using tables in layers. However, I think your issue may be that you may be mixing style syntax with JS syntax. try:
documents[yourlayername].bgcolor = red;
June 10th, 1999, 01:40 PM
document.layers[layername].bgColor = myColor
July 16th, 1999, 12:20 AM
As far as I know, when you use style syntax, and have anything with a '-' in it, you got to remove the '-' and capitalize the character after it to get it to work in JS.
So 'layer-background-color' would be