Setting a value kills a script
I'm working on my first script and I've hit a bit of a snag.
I have added a slider expression to a layer to which I later add an expression. (That part is working) The first two lines in the following code work as expected. Line one creates the slider effect and line two changes the name of the effect to the layer name plus what it controls.
Line three was intended to set the value of the slider, but if that line is left in the script, the script simply stops at that point, breaking out of the for loop that the code is in. As near as I can tell, I'm trying to set a value to a read only property, but I don't know what property I should be working with. I assume featherCrtl.property(1) is the slider's value... Maybe it's not. But I don't know what else would be the value.
Any help would be greatly appreciated.
Thanks,
Lars
var featherCrtl = selectedLayers.property("Effects").addProperty("ADBE Slider Control");
featherCrtl.name = selectedLayers.name + " Feather Control";
featherCrtl.property(1).setValue(myFeather);