Hey MofoMan2000.

Try deriving a norm expression that gets the distance from a fixed point, to a position on the line. If you have a parameterized x(t), y(t), z(t), then the norm will simply be ||.||^2 = (x(t) - x0)^2 + (y(t) - y0)^2 + (z(t) - z0)^2 where (x(t),y(t),z(t)) is the position of the line at parameter t, and (x0,y0,z0) is the fixed point.

By minimizing ||.||^2 (which is easier than minimizing the non-square version since you have square roots) you can find the closest point that way.