You may be using an iPhone charger or an unofficial one. Generally, iPhone chargers are too slow for iPads because they do not provide enough power for the iPad to stay on and charger the battery. If you don't have one already, use an official Apple iPad charger because they are rated for a higher wattage and provide the necessary power. You can tell what type of charger it is via the small grey writing on the bottom of the charger which will generally say 'iPod Charger' or 'iPhone Charger'.