Wrap/Bend/Warp part to surface of another part(and stretch)

I need to bend a part so that it follows the contour of asurface of another part. Is this possible? I need it for thegeneral case. I can write an add-in to help with the process ifneeded but I'd like to find the easiest way.

Example:

Suppose one has a curved surface S of a solid body with agroove/slot in it. Another part, say a "T beam", is to be matedwith the solid body at the groove. The T beam should be stretchedto fit in the grove(for example, mating both ends should "stretch"it) and the T beam should be "warped" to the surface.

Any ideas?

Thanks
SolidworksAssemblies