An empirical expression describing the lateral distribution of the nonequilibrium charge-carrier generation rate in GaN by a focused electron beam is obtained. The maximum nonequilibrium charge-carrier concentration as a function of the beam energy and diffusion length is calculated using this expression. Comparison of the results with values obtained using previously proposed approximate expressions provides an opportunity to evaluate the applicability of these approximations. Within the study of GaN by the cathodoluminescence and electron-beam-induced-current methods, the possibility to achieve a low injection level is analyzed considering the fact that the diffusion lengths of nonequilibrium charge carriers can be measured correctly only at low injection levels. It is shown that, in spite of the submicron values of the diffusion lengths in GaN, rather low beam currents are required to achieve a low injection level.