Exhibit 10.1



 Exhibit 10.1 
 TENTH AMENDMENT TO CREDIT AGREEMENT 
 THIS TENTH AMENDMENT TO CREDIT AGREEMENT (this
“Amendment”) is dated and effective as of December 21, 2007, by and between TREX COMPANY, INC., a Delaware corporation (sometimes hereinafter referred to herein as “Trex Inc.”), and BRANCH BANKING AND TRUST
COMPANY, a North Carolina state banking corporation, successor by merger to Branch Banking and Trust Company of Virginia (hereinafter referred to herein as the “Bank”). 
 Trex Inc., TREX Company, LLC, a Delaware limited liability company (“TREX LLC”), and the Bank are the original parties to that certain Credit
Agreement dated as of June 19, 2002, as amended by a First Amendment to Credit Agreement dated as of August 29, 2003, as further amended by a Second Amendment to Credit Agreement dated as of September 30, 2004, as further amended by a
Third Amendment to Credit Agreement dated as of March 31, 2005, as further amended by a Fourth Amendment to Credit Agreement dated as of July 25, 2005, as further amended by a Fifth Amendment to Credit Agreement dated as of
December 31, 2005, as further amended by a Sixth Amendment to Credit Agreement dated as of November 9, 2006, as further amended by a Seventh Amendment to Credit Agreement dated as of December 31, 2006, as further amended by an Eighth
Amendment to Credit Agreement dated as of March 16, 2007, as further amended by a Ninth Amendment to Credit Agreement dated as of June 12, 2007 and effective as of June 18, 2007 (as so amended and as it may hereafter be amended,
restated, supplemented, replaced or otherwise modified from time to time, the “Credit Agreement”). Subject to the terms and conditions contained in the Credit Agreement, the Bank agreed to extend to Trex Inc. and TREX LLC (i) a
revolving credit facility, with a letter of credit subfacility, in the aggregate amount of $70,000,000 for working capital financing of Trex Inc.’s and TREX LLC’s accounts receivable and inventory, to purchase new equipment and/or for
other general corporate purposes of Trex Inc. and TREX LLC, (ii) a term loan facility in the amount of $9,570,079.88 to refinance the Winchester Property (as defined in the Credit Agreement), and (iii) a term loan facility in the amount of
$3,029,920.12 to finance existing improvements to the Winchester Property. Effective December 31, 2002, TREX LLC merged with and into Trex Inc., with Trex Inc. being the surviving entity. As a result of such merger, Trex Inc. is the sole
borrower under the Credit Agreement and shall hereinafter sometimes be referred to in this Amendment as the “Borrower.” 
 The
Borrower has requested that the Bank modify certain financial covenants contained in the Credit Agreement, and the Bank is willing to do so upon the terms and conditions contained herein. 
 Accordingly, the Borrower and the Bank hereby agree as follows: 
 1. Capitalized terms used in this Amendment and not otherwise defined herein shall have the meanings assigned thereto in the Credit Agreement. 







 2. Section 2.01(c)iii. of the Credit Agreement is hereby amended by deleting the sentence at the end
of such Section in its entirety and substituting the following sentence in its place: 
 Notwithstanding clause (viii) above, the value
of Eligible Inventory (A) consisting of Eligible Inventory consigned to The Home Depot shall be equal to the lesser of (i) the actual value of the Eligible Inventory consigned to The Home Depot and (ii) $999,999.99, provided that if
the value of the Eligible Inventory consigned to The Home Depot is equal to or greater than $1,000,000 and the Borrower has fully complied with and remains in full compliance with all of the requirements set forth in Sections 4.4(d) and 5.3(a) of
the Security Agreement applicable to Inventory consigned to The Home Depot, sub-clause (ii) shall not apply and (B) consisting of Eligible Inventory consigned to Lowe’s Company, Inc. (“Lowe’s”) shall, notwithstanding
Section 4.4(e) of the Security Agreement and the last sentence of Section 4.4 of the Security Agreement, be equal to the lesser of (i) the actual value of the Eligible Inventory consigned to Lowe’s and (ii) $-0-, provided
that if (1) the Borrower shall have executed and delivered, and caused Lowe’s to have executed and delivered, to Branch Banking and Trust Company, as Collateral Agent (the “Collateral Agent”), a consignee letter in form and
substance acceptable to the Collateral Agent and (2) the Borrower has fully complied with and remains in full compliance with all of the requirements set forth in Section 5.3(a) of the Security Agreement, then sub-clause (ii) shall
not apply commencing on the Business Day immediately following the Business Day after the Collateral Agent shall have received such consignee letter from Lowe’s. 
 3. Section 6.11 of the Credit Agreement is hereby deleted in its entirety and the following Section is substituted in its place: 
 Section 6.11. Total Consolidated Senior Debt to Consolidated EBITDA Ratio. The Borrower will not, as of the end of any fiscal
quarter, permit the ratio of the Total Consolidated Senior Debt to Consolidated EBITDA (the “Total Consolidated Senior Debt to Consolidated EBITDA Ratio”) for the four-quarter period ended as of the end of such fiscal quarter to exceed the
following amounts for the following periods: (i) 9.0 to 1 for the period commencing on October 1, 2007 to and including December 31, 2007, (ii) 11.0 to 1 for the period commencing on January 1, 2008 to and including
March 31, 2008, and (iii) thereafter (A) 2.5 to 1 for each period commencing on April 1 of a calendar year to and including September 30 of such calendar year and (B) 3.0 to 1 for each period commencing on
October 1 of a calendar year to and including March 31 of the immediately succeeding calendar year. 
 4. Section 6.12 of the
Credit Agreement is hereby deleted in its entirety and the following Section is substituted in its place: 
 Section 6.12. Fixed Charge Coverage Ratio. The Borrower will not, as of the end of any fiscal quarter, permit the Fixed Charge Coverage Ratio for the four-quarter period ended as of the end of such fiscal quarter to be less than
the following amounts for the following periods: (i) 1.0 to 1 for the period commencing on October 1, 2007 to and including March 31, 2008, and (ii) 1.4 to 1 thereafter. 
  

 -2- 








 5. Section 6.15(b)(ii)(D) of the Credit Agreement is hereby deleted in its entirety and the
following Section is substituted in its place: 
 (D) (1) the Total Consolidated Debt to Total Consolidated Capitalization Ratio both
immediately prior to such proposed Acquisition and immediately after and giving effect to such proposed Acquisition shall be at least three percentage points lower than the maximum Total Consolidated Debt to Total Consolidated Capitalization Ratio
required by Section 6.10 on the date of such proposed Acquisition (e.g., if the proposed Acquisition occurs during the period commencing on April 1, 2007 to and including March 31, 2008, the Total Consolidated Debt to Total
Consolidated Capitalization Ratio both immediately prior to such proposed Acquisition and immediately after and giving effect to such proposed Acquisition shall not exceed 57%) and (2) the Pro Forma Total Consolidated Senior Debt to
Consolidated EBITDA Ratio shall be at least 0.5 lower than the maximum ratio of the Total Consolidated Senior Debt to Consolidated EBITDA required by Section 6.11 on the date of the proposed Acquisition (e.g., if the proposed Acquisition
occurs during the period commencing on October 1, 2007 to and including December 31, 2007, the Pro Forma Total Consolidated Senior Debt to Consolidated EBITDA Ratio shall not exceed 8.5 to 1); 
 6. The definition of the term, “Applicable Real Estate Term Loan Margin,” contained in the Definitions Appendix to the Credit Agreement is
hereby deleted in its entirety and the following definition is inserted in its place: 
 “Applicable Real Estate Term
Loan Margin” means (i) 2.75% for the period from December 21, 2007 through and including the first day of the month following receipt by the Bank of the consolidated financial statements described in Section 6.01(a) for the
period ending December 31, 2007 and (ii) thereafter shall be determined by reference to the Total Consolidated Senior Debt to Consolidated EBITDA Ratio in accordance with the following table: 
  

				
	 Total Consolidated Senior Debt to
 Consolidated EBITDA Ratio
	  	Applicable Real Estate
Term Loan Margin	 
	 Equal to or higher than 4.0 to 1
	  	3.75	%
	 Equal to or higher than 3.5 to 1 but lower than 4.0 to 1
	  	3.00	%
	 Equal to or higher than 3.0 to 1 but lower than 3.5 to 1
	  	2.75	%
	 Equal to or higher than 2.5 to 1 but lower than 3.0 to 1
	  	2.50	%
	 Equal to or higher than 2.0 to 1 but lower than 2.5 to 1
	  	2.25	%
	 Equal to or higher than 1.5 to 1 but lower than 2.0 to 1
	  	2.00	%
	 Equal to or higher than 1.0 to 1 but lower than 1.5 to 1
	  	1.75	%
	 Lower than 1.0 to 1
	  	1.50	%

  

 -3- 








 Except during the initial period described in clause (i) above, the Applicable Real Estate Term Loan
Margin will be automatically adjusted as of the first day of the month following receipt by the Bank of consolidated financial statements of the Borrower and its Consolidated Subsidiaries pursuant to Section 6.01(a) or Section 6.01(b)
demonstrating to the Bank’s reasonable satisfaction that there has been a change in the Total Consolidated Senior Debt to Consolidated EBITDA Ratio which would cause a change in the Applicable Real Estate Term Loan Margin in accordance with the
preceding table. Any such change shall apply to Real Estate Term Loans 1, 2 & 3 outstanding on such effective date. At all times after and during the continuance of a Default with respect to the Borrower’s obligations under
Section 6.01(a) or Section 6.01(b) until the delivery of the applicable financial statements required pursuant thereto, the Applicable Real Estate Term Loan Margin shall be 3.75%. 
 7. The definition of the term, “Applicable Revolving Loan Margin,” contained in the Definitions Appendix to the Credit Agreement is hereby
deleted in its entirety and the following definition is substituted in its place: 
 “Applicable Revolving Loan
Margin” means (i) 2.50% for the period from December 21, 2007 through and including the first day of the month following receipt by the Bank of the consolidated financial statements described in Section 6.01(a) for the period
ending December 31, 2007 and (ii) thereafter shall be determined by reference to the Total Consolidated Senior Debt to Consolidated EBITDA Ratio in accordance with the following table: 
  

				
	 Total Consolidated Senior Debt to
Consolidated EBITDA Ratio
	  	Applicable Revolving
Loan Margin	 
	 Equal to or higher than 4.0 to 1
	  	3.50	%
	 Equal to or higher than 3.5 to 1 but lower than 4.0 to 1
	  	2.75	%
	 Equal to or higher than 3.0 to 1 but lower than 3.5 to 1
	  	2.50	%
	 Equal to or higher than 2.5 to 1 but lower than 3.0 to 1
	  	2.25	%
	 Equal to or higher than 2.0 to 1 but lower than 2.5 to 1
	  	2.00	%
	 Equal to or higher than 1.5 to 1 but lower than 2.0 to 1
	  	1.75	%
	 Equal to or higher than 1.0 to 1 but lower than 1.5 to 1
	  	1.50	%
	 Lower than 1.0 to 1
	  	1.25	%

  

 -4- 








 Except during the initial period described in clause (i) above, the Applicable Revolving Loan Margin
will be automatically adjusted as of the first day of the month following receipt by the Bank of consolidated financial statements of the Borrower and its Consolidated Subsidiaries pursuant to Section 6.01(a) or Section 6.01(b)
demonstrating to the Bank’s reasonable satisfaction that there has been a change in the Total Consolidated Senior Debt to Consolidated EBITDA Ratio which would cause a change in the Applicable Revolving Loan Margin in accordance with the
preceding table. Any such change shall apply to the Revolving Loans outstanding on such effective date or made on or after such effective date. At all times after and during the continuance of a Default with respect to the Borrower’s
obligations under Section 6.01(a) or Section 6.01(b) until the delivery of the applicable financial statements required pursuant thereto, the Applicable Revolving Loan Margin shall be 3.50%. 
 8. Schedule 5.05 to the Credit Agreement is hereby deleted in its entirety and a new Schedule, which is attached to this Amendment and labeled
Schedule 5.05, is substituted in its place. 
 9. The Borrower hereby represents and warrants to the Bank (which representations and
warranties shall survive the execution and delivery of this Amendment) that: 
 (a) It is in compliance with all of the terms,
covenants and conditions of the Credit Agreement, as amended by this Amendment, and each of the other Loan Documents. 
  

 -5- 








 (b) There exists no Default or Event of Default under the Credit Agreement, as amended by
this Amendment, and no event has occurred or condition exists which, with the giving of notice or lapse of time, or both, would constitute such a Default or Event of Default. 
 (c) The representations and warranties contained in Article V of the Credit Agreement are, except to the extent that they relate solely to
an earlier date or except to the extent that they relate solely to TREX LLC, true in all material respects with the same effect as though such representations and warranties had been made on the date of this Amendment. 
 (d) The execution, delivery and performance by the Borrower of this Amendment are within its corporate powers, have been duly authorized
by all necessary corporate action, require no action by or in respect of, or filing with, any governmental body, agency or official and do not contravene or constitute (with or without the giving of notice or lapse of time or both) a default under
any provision of applicable law or of the organizational documents of the Borrower or any Subsidiary or of any agreement, judgment, injunction, order, decree or other instrument binding upon or affecting the Borrower or any Subsidiary or result in
the creation or imposition of any Lien on any asset of the Borrower or any of its Subsidiaries other than a Lien in favor of the Bank as provided in the Security Agreement. 
 (e) This Amendment constitutes the valid and binding agreement of the Borrower, enforceable against the Borrower in accordance with its
terms, except as such enforceability may be limited by bankruptcy, insolvency or similar laws affecting creditors’ rights generally and by equitable principles of general applicability (regardless of whether such enforceability is considered in
a proceeding in equity or at law). 
 (f) Except as set forth on Schedule 5.05 to the Credit Agreement, there is no
material action, suit, proceeding or investigation pending against, or to the knowledge of the Borrower threatened against, contemplated or affecting, the Borrower or any of its Subsidiaries before any court, arbitrator or governmental body, agency
or official which has, or could reasonably be expected to have, individually or in the aggregate, a Material Adverse Effect, or which in any manner draws into question the validity or enforceability of this Amendment or any of the other Loan
Documents, and there is no basis known to the Borrower or any of its Subsidiaries for any such action, suit, proceeding or investigation. 
 10. The Bank’s agreement to enter into this Amendment is subject to the following conditions precedent: 
 (a)
The Borrower shall have executed and delivered to the Bank this Amendment. 
 (b) The Borrower, JPMorgan Chase Bank, N.A., as
issuing bank (the “Issuing Bank”), and JPMorgan Chase Bank, N.A., as administrative agent (the “Administrative Agent”), shall have executed and delivered an amendment to the Chase Credit Agreement in form and substance acceptable
to the Bank. 
  

 -6- 








 (c) The Bank shall have received a favorable opinion of counsel to the Borrower addressed
to the Bank, dated as of the date hereof and satisfactory in form and substance to the Bank, as to the due authorization, execution, delivery and enforceability of this Amendment and such other matters as the Bank shall reasonably request.

 (d) The Borrower shall have executed and delivered, or caused to be executed and delivered, to the Bank such other and
further documents, certificates, opinions and other papers as the Bank shall reasonably request; and the Borrower shall have paid all fees due to the Bank. 
 11. Except as expressly amended hereby, the terms of the Credit Agreement shall remain in full force and effect in all respects, and the Borrower hereby reaffirms its obligations under the Credit Agreement, as amended
by this Amendment, and each of the other Loan Documents. The Borrower hereby waives any claim, cause of action, defense, counterclaim, setoff or recoupment of any kind or nature that it may assert against the Bank arising from or in connection with
the Credit Agreement, as amended by this Amendment, any of the Loan Documents, or the transactions contemplated thereby or hereby that exist on the date hereof or arise from facts or actions occurring prior hereto or on the date hereof. Nothing
contained in this Amendment shall be construed to constitute a novation with respect to the obligations described in the Credit Agreement. 
 12. All references to the Credit Agreement in any of the Loan Documents, or any other documents or instruments that refer to the Credit Agreement, shall be deemed to be references to the Credit Agreement as amended by this Amendment.

 13. This Amendment shall be construed in accordance with and governed by the laws of the Commonwealth of Virginia. 
 14. Any Dispute arising out of or related to this Amendment or any of the other Loan Documents shall be resolved by binding arbitration as provided in
Section 9.07 of the Credit Agreement. TO THE FULLEST EXTENT PERMITTED BY LAW, THE PARTIES HERETO HEREBY IRREVOCABLY WAIVE THEIR RESPECTIVE RIGHTS TO A JURY TRIAL WITH RESPECT TO ANY DISPUTE. 
 15. This Amendment may be executed in any number of counterparts, each of which shall be an original, but all of which taken together shall constitute
one and the same instrument. 
 16. This Amendment shall be binding upon and inure to the benefit of the parties hereto and their respective
successors and assigns. The Borrower shall not have the right to assign any of its rights or obligations under or delegate any of its duties under the Credit Agreement, as amended by this Amendment, or any of the other Loan Documents. 
 17. The Borrower hereby agrees that it will pay on demand all out-of-pocket expenses incurred by the Bank in connection with the preparation of this
Amendment and all other related documents, including but not limited to the fees and disbursements of counsel for the Bank. 
  

 -7- 








 18. This Amendment supersedes and replaces in its entirety numbered paragraph 2 on page 2 of the limited
waiver letter issued by the Bank to the Borrower dated and effective as of September 30, 2007. This Amendment represents the final agreement between the Borrower and the Bank with respect to the subject matter hereof, and may not be
contradicted, modified or supplemented in any way by evidence of any prior or contemporaneous written or oral agreements of the Borrower and the Bank. 
 [Remainder of Page Intentionally Left Blank] 
  

 -8- 








 IN WITNESS WHEREOF, the Borrower and the Bank have caused this Amendment to be executed by their
duly authorized officers under seal as of the date first written above. 
  

					
	TREX COMPANY, INC.	 	
			
	By:	 	/s/ Andrew U. Ferrari	 	(SEAL)
	Name:	 	Andrew U. Ferrari	 	
	Title:	 	Chief Executive Officer	 	
	
	BRANCH BANKING AND TRUST COMPANY
			
	By:	 	/s/ David A. Chandler	 	(SEAL)
	Name:	 	David A. Chandler	 	
	Title:	 	Senior Vice President	 	


  

 -9-