(a) Upon refusal of a lawful demand for inspection under this chapter, or a lawful demand pursuant to Section 8330 or Section 8333, the superior court of the proper county, or the county where the books or records in question are kept, may enforce the demand or right of inspection with just and proper conditions or may, for good cause shown, appoint one or more competent inspectors or independent accountants to audit the financial statements kept in this state and investigate the property, funds and affairs of any corporation and of any subsidiary corporation thereof, domestic or foreign, keeping records in this state and to report thereon in such manner as the court may direct.
(b) All officers and agents of the corporation shall produce to the inspectors or accountants so appointed all books and documents in their custody or power, under penalty of punishment for contempt of court.
(c) All expenses of the investigation or audit shall be defrayed by the applicant unless the court orders them to be paid or shared by the corporation.