Did this for a friend of mine, maybe somebody else can use it too. The task was to find the surface intersection points for a line, then draw only the part of the line from the start point to the closest intersection with the surface. I think this should work for Curves too, but i didn't try that.
link: http://grasshopper3d.googlegroups.com/web/simons_intersection_new.ghx?gsc=uKlmFgsAAADVPGKacP4eKNTevqM0ydqC
