Thanks! It works great now.

By the way, naming a variable storedSpline does not automatically create a spline. You need to call ComputeClosedSpline. See here :
Don't pay attention to that name. I was reusing that name from another piece of code that did use a spline.