The output power of the inverter of a PV system is directly affected by the DC-link voltage. Hence an adaptive Proportional Integral controller based on Artificial Neural Networks is developed in this paper. MATLAB/Simulink is used for the simulation of the studied system in order to evaluate the performance of the proposed methods. Simulation results show that the proposed API-ANN is faster to track the DC-link voltage than the conventional method. The injected harmonics to the grid were significantly reduced with API-ANN (0.08 % of total harmonic distortion) in comparison with the classic PI with 4.23 %. The API-ANN gives a good performance than the classic PI.