  This is the fourth paper in a series in which we attempt to put constraints
on the flattening of dark halos in disk galaxies. We observed for this purpose
the HI in edge-on galaxies, where it is in principle possible to measure the
force field in the halo vertically and radially from gas layer flaring and
rotation curve decomposition respectively. We have analysed the HI channel maps
to accurately measure all four functions that describe the HI kinematics and 3D
distribution: the radial HI surface density, the HI vertical thickness, the
rotation curve and the HI velocity dispersion. In this paper we analyse these
data for the edge-on galaxy UGC7321. We measured the stellar mass distribution
($M=3\times10^8$ \msun with $M/L_R\lesim0.2$), finding that the vertical force
of the gas disk dominates the stellar disk at all radii. We find that the
vertical force puts a much stronger constraint on the stellar mass-to-light
ratio than rotation curve decomposition. Fitting of the vertical force field
derived from the flaring and velocity dispersion of the HI revealed that
UGC7321 has a spherical halo density distribution with a flattening of $q = c/a
= 1.0 \pm 0.1$.

Cosmology and Nongalactic Astrophysics;Astrophysics of Galaxies