We investigate the electrical injection of spin-polarized electrons into a semiconductor [Al(GaAs)] heterostructure from ferromagnetic FeCo metal through an AlOx tunnel barrier. We have developed the optical oblique Hanle effect approach for the quantitative analysis of electrical spin injection into semiconductors. This technique is based on the manipulation of the electron spins within a semiconductor when spin polarized electrons have been injected. This allows us to clearly separate the effects caused by spin injection from others, that are magneto-optical, Zeeman, etc. Simultaneously, the oblique Hanle effect approach provides additional information on the spin dynamics in the semiconductor. In the FeCo/AlOx/Al(GaAs) heterostructures we observe spin injection of 21% and 16% at 80 and 300 K, respectively. The importance of electron thermalization effects and the impact of the doping level of the semiconductor for practical investigation of spin injection by optical means are demonstrated.