How much energy is released a year of all the lightning on earth?
Some basic math on this:

About 100 bolts of lightning hit the Earth every second and they average about a billion joules of energy be bolt.   That's 3.1 billion lightning strikes per year, coming to about 3.1 billion billion joules per year, or about 860 billion kilowatt-hours (kwh) of electrical energy per year.   

That estimate is pretty rough as some estimates have as much as 5 billion joules per bolt of lightning, pushing it up over 4 trillion kwh/year.

Total human electrical usage, per source is about 18.1% of 104 trillion kwh/year, 2012 numbers, 18.9 trillion kwh/year of electricity generated.    So even if all the lightning energy was utilized (which would be unlikley for a few reasons), it would be somewhere in the 4%-20% range of our total electrical demand, which isn't bad, but I think that's the answer to your question.  There's not enough energy in all the lightning on Earth to supply our electrical demand.  

Wikipedia has an article on the logistical difficulties.   It's perhaps doable, to some extent, but at best, lightning could provide only a small percentage of our electrical needs, unlike solar panels which could provide, at least in total energy, well in excess of our electrical needs.   Solar runs into problems like it's not always on, which is a limiting factor to it's usefulness, but in terms of total energy provided it's much easier and much more abundant than harnessing lightning.