Narrative:

Lost all electrical power while retracting the landing gear [and it] never came back online after the gear came up. There were several airplanes in the pattern taking off and landing; so I maintained my assigned heading and stayed below class B airspace until exiting. I landed at first airport possible outside the class B to fix the problem.

Google
 

Original NASA ASRS Text

Title: A total electrical failure on a Lancair Legacy was successfully addressed when the pilot landed at the first available airport after exiting the class B area around the departure airport.

Narrative: Lost all electrical power while retracting the landing gear [and it] never came back online after the gear came up. There were several airplanes in the pattern taking off and landing; so I maintained my assigned heading and stayed below class B airspace until exiting. I landed at first airport possible outside the class B to fix the problem.

Data retrieved from NASA's ASRS site as of April 2012 and automatically converted to unabbreviated mixed upper/lowercase text. This report is for informational purposes with no guarantee of accuracy. See NASA's ASRS site for official report.