  Angular distribution measurements of $^2$H($^7$Be,$^7$Be)$^2$H and
$^2$H($^7$Be,$^8$B)$n$ reactions at $E_{c.m.}\sim$~4.5 MeV were performed to
extract the astrophysical $S_{17}(0)$ factor using the asymptotic normalization
coefficient (ANC) method. For this purpose a pure, low emittance $^7$Be beam
was separated from the primary $^7$Li beam by a recoil mass spectrometer
operated in a novel mode. A beam stopper at 0$^{\circ}$ allowed the use of a
higher $^7$Be beam intensity. Measurement of the elastic scattering in the
entrance channel using kinematic coincidence, facilitated the determination of
the optical model parameters needed for the analysis of the transfer data. The
present measurement significantly reduces errors in the extracted
$^7$Be(p,$\gamma$) cross section using the ANC method. We get
$S_{17}$~(0)~=~20.7~$\pm$~2.4 eV~b.
