The recently experimentally synthesized monolayer MoSi2N4 and WSi2N4 (Science 369, 670-674 (2020)) lack inversion symmetry, which allows them to become piezoelectric. In this work, based on ab initio calculations, we report structure effect on intrinsic piezoelectricity in septuple-atomic-layer MSi2N4 (M=Mo and W), and six structures (alpha(i) (i=1 to 6)) are considered with the same space group. These structures can connect to each other through translation, mirror and rotation operations of double layer unit Si2N2. It is found that MSi2N4 (M=Mo and W) with alpha(i )(i = 1 to 6) all are indirect band gap semiconductors. Calculated results show that MoSi2N4 and WSi2N4 monolayers have the same structural dependence on piezoelectric strain and stress coefficients (d(11) and e(11)), together with the ionic and electronic contributions to e(11). The alpha(5) phase has largest d(11) for both MoSi2N4 and WSi2N4, which are larger than 2.9 pm/V. Finally, we investigate the intrinsic piezoelectricity of monolayer MA(2)Z(4) (M=Cr, Mo and W; A=Si and Ge; Z=N and P) with alpha(1) and alpha(2) phases expect CrGe2N4, because they all are semiconductors and their enthalpies of formation between alpha(1) and alpha 2 phases are very close. The most important result is that monolayer MA(2)Z(4) containing P atom have more stronger piezoelectric polarization than one including N atom. The largest d(11) among MA(2)N(4) materials is 1.85 pm/V, which is close to the smallest d(11) of 1.65 pm/V in MA(2)P(4) monolayers. For MA(2)P(4), the largest d(11) is up to 6.12 pm/V. Among the 22 monolayers, alpha(1)-CrSi2P4, alpha(1)-MoSi2P4, alpha(1)-CrGe2P4, alpha(1)-MoGe2P4 and alpha(2)-CrGe2P4 have large d(11), which are greater than or close to 5 pm/V, a typical value for bulk piezoelectric materials. These materials are recommended for experimental exploration. Our study reveals that the MA(2)Z(4) family have the potential applications in piezoelectric field.