The recently proposed method to determine the hard body distribution function on the basis of values of the residual chemical potentials of a pair of hard molecules and that of the corresponding combined body is applied to describe behavior of the inhomogeneous systems of pure heteronuclear hard dumbbells or a mixture of heteronuclear dumbbells with hard spheres near a hard wall. Two variants of the main orientation of the dumbbells – i.e. the perpendicular orientation with respect to the hard planar wall – are studied and several values of the packing fraction are considered. The used simple method yields a fair prediction of the slices of the distribution function or average correlation function for the heteronuclear dumbbell (composed of two hard spheres with rather different diameters (σ2/σ1 = 0.5) and site–site separation (l/σ1 = 0.625)) near a wall; in the case of mixtures of hard spheres and hard heteronuclear dumbbells the hard sphere diameter σhs = σ1.