View Single Post
  #5   Report Post  
Jon Peltier
 
Posts: n/a
Default

He he, I used a much less advanced technique than you did.

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services
Tutorials and Custom Solutions
http://PeltierTech.com/
_______


Tushar Mehta wrote:

Hi Jon,

I cannot derive the formula you got but it cannot work for any vertical
or horizontal line.

For an approach from MathWorld see
http://mathworld.wolfram.com/Point-L...mensional.html

It gives the distance of (x0,y0) from ax+by+c=0 as
abs(a*x0+b*y0+c)/sqrt(a^2+b^2)