I assume that you are talking about line segments on a 2D plane and "projection" means "orthogonal projection". That is, the projection of $A$ on a line is the foot of perpendicular from $A$ to that line, and so on and so forth.
Let $A=(a_1,a_2),\ B=(b_1,b_2),\ C=(c_1,c_2)$ and $D=(d_1,d_2)$. Let the third line passes through some two points $P=(p_1,p_2)$ and $Q=(q_1,q_2)$. So the vector $ \vec{u}=(u_1,u_2)=\frac{\vec{PQ}}{\|\vec{PQ}\|}= \frac{1}{\sqrt{(q_1-p_1)^2+(q_2-p_2)^2}}(q_1-p_1,\,q_2-p_2). $ has length $1$ and it is parallel to the third line. Now, if you set $P=(p_1,p_2)$ as the origin, and let the half of the third line that extends from $P$ and points to the direction of $\vec{u}$ as the "positive $u$-axis", and the other half as the "negative $u$-axis", then the "$u$-coordinate" of the projection of $A$ on the third line is given by $\vec{PA}\cdot\vec{u}$, i.e. $(a_1-p_1)u_1+(a_2-p_2)u_2.$ Replace $(a_1,a_2)$ in last expression by $(b_1,b_2), (c_1,c_2)$ or $(d_1,d_2)$, you get the $u$-coordinates of $B,C$ or $D$. You can now do your computation as if $A,B,C,D$ all lie on the same $u$-axis, with their corresponding $u$-coordinates.