EX-23.4 5 l24372bexv23w4.htm EX-23.4 EX-23.4
 

Exhibit 23.4
Consent of Independent Registered Public Accounting Firm
We consent to the reference to our firm under the caption “Experts” in Amendment No. 1 to the Registration Statement (Form S-4, No. 333-142331) and related Prospectus of United Bankshares, Inc. for the registration of 3,648,817 shares of its common stock and to the incorporation by reference therein of our report dated February 22, 2007, with respect to the consolidated financial statements of United Bankshares, Inc., United Bankshares, Inc. management’s assessment of the effectiveness of internal control over financial reporting, and the effectiveness of internal control over financial reporting of United Bankshares, Inc., included in its Annual Report (Form 10-K) for the year ended December 31, 2006, filed with the Securities and Exchange Commission.
/s/ Ernst & Young, LLP
Charleston, West Virginia
June 1, 2007