Solar chargers are awfully expensive, compared to battery-powered; also, they are mostly in the very weak to moderate strength range so they will not be appropriate for all applications.
Even apart from the significantly higher initial purchase price, they are NOT cost-free --- you will need to replace the battery periodically, after something like several years if your fence is very carefully maintained, but more frequently if you EVER let the fence ground out and the battery gets all the way drained. (With a bum battery, the fence will only work during daylight and evening hours). The battery for my solar powered unit is like $40 a pop, dunno about other makes/models.
Frankly, your best bet is plugging into wall current if it's an option (i.e. if you have 120 v running close enough to your fence and have a place to put the charger where it'll be out of the weather but it won't burn down your house or barn if it catches fire from a lightning strike.
If you can't use wall current, then a battery powered unit really makes the most sense in most cases. Solar tends to be weaker and more expensive. But if you just *want* a solar powered unit, and it's strong enough for your needs, then there is no particular reason to avoid it. As you have probably detected, I have one myself
Good luck,
Pat