Form: N-2

Initial filing of a registration statement on Form N-2 for closed-end investment companies

June 27, 2011

Exhibit (n)(1)

Consent of Independent Registered Public Accounting Firm

We consent to the reference to our firm under the captions “Selected Consolidated Financial and Other Data”, “Senior Securities” and “Independent Registered Public Accounting Firm” and to the use of our reports (a) dated March 9, 2011, with respect to the consolidated financial statements and financial highlights of Triangle Capital Corporation as of December 31, 2010 and 2009 and for the three years ended December 31, 2010, and the consolidated financial highlights for the year ended December 31, 2007 and combined financial highlights for the year ended December 31, 2006; (b) dated March 9, 2011, with respect to the effectiveness of internal control over financial reporting of Triangle Capital Corporation as of December 31, 2010 and (c) dated April 1, 2011 with respect to the senior securities table of Triangle Capital Corporation as of December 31, 2010, in the Registration Statement (Form N-2) and related Prospectus of Triangle Capital Corporation.

/s/ Ernst & Young LLP

Raleigh, North Carolina

June 24, 2011