It is well known that electric field penetration through a small aperture in a perfectly conducting plane behaviors like an electric dipole. When excited by uniform electric field, the dipole moment has analytical solution for elliptical apertures and numerical/experimental values for other shapes. In this paper, for the case of nonuniform field excitation, based on the electrostatic reciprocity theorem, the closed-form expression of electric dipole moment is derived for elliptical apertures. This expression is in integral form, and its integrand is the product of the nonuniform electric field distribution and the potential distribution when excited by uniform field in the aperture plane. Taking a point charge located on the aperture plane as an example of nonuniform field excitation, the dipole moment is calculated using the proposed closed-form expression. The validation is verified by comparisons with exact integral solution for circular apertures and with finite element simulations for elliptical apertures.