  Let $G=$SL$(2,R)\ltimes(R^2)^{\oplus k}$ and let $\Gamma$ be a congruence
subgroup of SL$(2,Z)\ltimes(Z^2)^{\oplus k}$. We prove a polynomially effective
asymptotic equidistribution result for special types of unipotent orbits in
$\Gamma\backslash G$ which project to pieces of closed horocycles in
SL$(2,Z)\backslash$SL$(2,R)$. As an application, we prove an effective
quantitative Oppenheim type result for the quadratic form
$(m_1-\alpha)^2+(m_2-\beta)^2-(m_3-\alpha)^2-(m_4-\beta)^2$, for
$(\alpha,\beta)$ of Diophantine type, following the approach by Marklof [24]
using theta sums.
