Apple says, repair guys say? Are these repair guys Apple techs, or Apple certified techs?
Anyway, the most common reason for the iPad to only charge when it is off is that the power supply is underpowered. If you are using anything but the original power supply that came with the iPad, then it may not supply enough power. This includes USB ports on your computer, and power supplies for other iOS devices like iPhones, iPods, and iPad Minis.
If you are using the original power supply, perhaps it is not working properly any more. You can try an alternate power supply, but make sure it it rated for charging an iPad (approximately 2A at 5V, or 10W). More is ok. Less may not be enough to charge the iPad while in use.
Though less likely to be the issue, you can try another cable as well.
The chance that it is software is almost negligible. If it is, then restoring the iPad should fix it.