Exhibit 10.51



MANAGEMENT FEE SUBORDINATION AGREEMENT



THIS MANAGEMENT FEE SUBORDINATION AGREEMENT (this Agreement), is made and entered into as of this
25th day of October, 2004, by and among PW Eagle, Inc., a Minnesota corporation (the Company), Spell Capital Partners LLC, a Minnesota limited liability company (the Manager), Fleet Capital
Corporation, a Rhode Island Corporation (Agent), and Churchill Capital Partners IV, L.P., a Delaware limited partnership (Churchill).



WITNESSETH:



A. The Company and Agent have entered into that certain Fourth Amended and Restated Loan and Agreement of even date herewith (as the same may be amended,
supplemented or otherwise modified from time to time, the Senior Credit Agreement) pursuant to which, among other things, Agent and the other Lenders party thereto have agreed, subject to the terms and conditions set forth in the
Senior Credit Agreement, to make certain loans and financial accommodations to the Company. The Senior Credit Agreement and the documents and instruments executed in connection therewith are hereinafter collectively referred to as the
Senior Credit Documents;



B. The Company and
Churchill (in such capacity, the Senior Note Purchaser) have entered into a Senior Subordinated Note Purchase Agreement of even date herewith (as the same may be amended, supplemented or otherwise modified from time to time, the
Senior SubordinatedNote Purchase Agreement) pursuant to which, among other things, the Senior Note Purchaser has agreed to purchase senior subordinated promissory notes of the Company. The Senior Subordinated Note Purchase
Agreement and the documents and instruments executed in connection therewith are hereinafter collectively referred to as the Senior SubordinatedNote Documents;



C. The Company and Churchill (in such capacity the Junior Note Purchaser) have entered into a Junior
Subordinated Note Purchase Agreement of even date herewith (as the same may be amended, supplemented or otherwise modified from time to time, the Junior Subordinated Note Purchase Agreement and, together with the Senior
Subordinated Note Purchase Agreement, the Note Purchase Agreements) pursuant to which, among other things, the Junior Note Purchaser has agreed to purchase junior subordinated promissory notes of the Company. The Junior
Subordinated Note Purchase Agreement and the documents and instruments executed in connection therewith are hereinafter collectively referred to as the Junior Subordinated Note Documents and, together with the Senior Subordinated
Note Documents, the Note Documents);



D. The
Agent and the Churchill are hereinafter collectively referred to as the Senior Creditors to the extent there are any amounts due and owing to such lender under its respective portion of the Senior Indebtedness;





---

E. From time to time on and after the date hereof, the Manager intends to provide certain services to or
for the benefit of the Company, pursuant to a Management Agreement, dated , between the Manager and the Company (the Management Agreement), and the
Manager is to receive certain consulting and other fees (the Management Fees) in exchange for such services actually rendered to the Company and reimbursement of actual out-of-pocket costs and expenses (Actual
Expenses) reasonably incurred in connection therewith;



F. The payment of Management Fees and Actual Expenses by the Company, either directly or indirectly by dividend, distribution or otherwise, to the Manager is limited pursuant to the Note Purchase Agreements and the Senior Credit Agreement;



G. The principal, interest, fees, indemnities and all other
sums due and owing pursuant to the Senior Credit Documents and the Note Documents, including without limitation, any of the foregoing obligations and amounts which would become due or accrue or arise but for the commencement of any applicable
Bankruptcy Proceeding (as defined below), whether or not a claim is allowed for the same in any such proceeding, are hereinafter collectively referred to as the Senior Indebtedness to the extent there are any amounts due and owing
under any of the instruments evidencing such Senior Indebtedness;



H. The Senior Creditors are unwilling to extend financial accommodations to the Company unless the Manager executes this Agreement; and



I. The Manager is of the opinion that it would be in its best interest to assist the Company in obtaining credit accommodations from the Senior Creditors
and therefore is willing to execute this Agreement.



NOW,
THEREFORE, in consideration of the premises and other good and valuable consideration, the receipt and sufficiency of which are hereby acknowledged, the parties hereto hereby agree as follows:



1. FULL SUBORDINATION. The payment by the Company of all the
Management Fees, Actual Expenses and all other obligations of the Company to the Manager of every type and description, whether now existing or hereafter created or incurred and whether several or joint and several (all such indebtedness hereinafter
collectively referred to as Subordinated Indebtedness), is hereby expressly subordinated to the extent and in the manner hereinafter specifically set forth to the payment in full in cash of all of the Senior Indebtedness.



2. LIMITATION AND SUBORDINATION OF PAYMENTS. In no
event shall Company, directly or indirectly, (x) pay Management Fees to the Manager which exceed $624,000 per year (payable no less frequently than quarterly) or (y) reimburse the Manager for other than reasonable Actual Expenses, in any case while
any obligation remains owing pursuant to the Senior Indebtedness. Notwithstanding the foregoing, the Manager will not demand, receive or accept any cash payment from the Company in respect of Management Fees in the event that and so long as an Event
of Default (as defined in the Senior Credit Agreement and/or



2



---

the Note Purchase Agreements) has occurred and is continuing or is or would be caused by the making of such payment of the Management Fees.



3. PAYMENT OVER TO SENIOR CREDITORS. In the event that the Manager
shall receive any cash payment on the Subordinated Indebtedness which it is not entitled to receive under the provisions of the foregoing Section 2 at the time of receipt, the Manager will hold the amount so received in trust for Agent, Senior Note
Purchaser, or Junior Note Purchaser as their respective rights are stated in (i) the Senior Subordination Agreement dated as of even date herewith among the Agent, Senior Note Purchaser, and Junior Note Purchaser (Senior Subordination
Agreement) and (ii) the Junior Subordination Agreement dated as of even date herewith between Senior Note Purchaser and Junior Note Purchaser (Junior Subordination Agreement) and will forthwith turn over such payment to
such party in the form received (except for the endorsement of the Manager where necessary) for application on indebtedness due under the Senior Credit Documents or the Note Documents (whether due or not due) in such manner of application as
required pursuant to the Senior Subordination Agreement and the Junior Subordination Agreement. In the event of the failure of the Manager to make any endorsement required under this Agreement, Agent, Churchill or any of their respective officers or
employees on behalf of such Senior Creditor, is hereby irrevocably appointed as the attorney-in-fact for the Manager to make the same in the Managers name.



4. PROHIBITION ON EXERCISE OF REMEDIES. The Manager will not, without Senior Creditors prior written consent,
commence, prosecute or participate in any action or proceeding against Company to recover all or any part of the Subordinated Indebtedness, or join with any creditor (unless the Senior Creditors shall so join) in bringing any proceedings (a
Bankruptcy Proceeding) against Company under any bankruptcy, reorganization, readjustment of debt, arrangement of debt, receivership, liquidation or insolvency law or statute of the federal or any state government, unless and until the
Senior Indebtedness has been paid in full. Notwithstanding the foregoing, the Manager may file proofs of claim against Company, in any Bankruptcy Proceeding involving Company. Any assets or other proceeds of any suit, action or proceeding against
Company obtained by the Manager in violation of this Agreement shall in any event be held in trust by it for the benefit of the Senior Creditors and promptly paid or delivered to Agent for the benefit of Senior Creditors in the form received until
all Senior Indebtedness is indefeasibly paid in full in cash and all commitments to lend under the Senior Credit Documents shall have been terminated.



5. SECURITY. The Manager warrants and represents that the Subordinated Indebtedness is unsecured and agrees that (i) the Manager hereafter will not
accept any security therefor from the Company or from any other person or entity for the benefit the Company and (ii) in the event the Manager does obtain any such security for the Subordinated Indebtedness, at the request of any of the Senior
Creditors, the Manager shall execute and deliver to the Senior Creditors such termination statements and releases as the Senior Creditors may reasonably request to release such security interest in or lien against such property or such other
documents as the Senior Creditors may reasonably request to assign to the Senior Creditors the benefit of such security interests or liens.



6. PAYMENTS SET ASIDE. To the extent that any of the Senior Creditors receive payments on, or proceeds of any collateral for, the Senior
Indebtedness which are subsequently



3



---

avoided, invalidated, declared to be fraudulent or preferential, set aside and/or required to be repaid to a trustee, receiver or any other party under any
bankruptcy law, state or federal law, common law or equitable cause, then, to the extent of such payment or proceeds received, the Senior Indebtedness, or part thereof, intended to be satisfied shall be revived and continue in full force and effect
as if such payments or proceeds had not been received by the Senior Creditors.



7. INTERPRETATION. None of the provisions of this Agreement shall be deemed or construed to constitute a commitment or any obligation on the part of the Senior Creditors to make any future loans or other
extensions of credit or financial accommodation to the Company.



8. CONTINUING NATURE OF SUBORDINATION. This Agreement shall constitute a continuing agreement of subordination, and the Senior Creditors may continue, without consent of the Manager, to make loans and extend other credit for
financial accommodation to or for the account of the Company in reliance upon this Agreement.



9. WAIVER. No waiver shall be deemed to be made by any of the Senior Creditors of any of their rights hereunder unless the same shall be in writing signed on behalf of such Senior Creditors, and each such
waiver, if any, shall be a waiver only with respect to the specific matter or matters to which the waiver relates and shall in no way impair the rights of such Senior Creditors or the obligation of the Manager to such Senior Creditors in any other
respect at any other time.



10. BINDING FORCE AND
EFFECT. This Agreement and every part hereof shall inure to the benefit of and be binding upon the parties hereto and their heirs, legal representatives, successors and assigns, from and after the date of its execution and delivery. Notice of
acceptance by the Senior Creditors of this Agreement or of reliance by Senior Creditors upon the subordination herein contained is hereby waived by the Manager.



11. COMPLIANCE BY COMPANY. The Company agrees that it will not make a payment of the Subordinated Indebtedness nor consent to or participate in
any act whatsoever which payment or act is in violation of any of the provisions of this Agreement. The Company expressly acknowledges that any violation of any of the provisions of this Agreement by the Company is an Event of Default under each of
the Senior Credit Agreement, the Senior Subordinated Note Purchase Agreement and the Junior Subordinated Note Purchase Agreement.



12. PROVISIONS SOLELY TO DEFINE RELATIVE RIGHTS. This Agreement is not intended to modify any of the relative rights and priorities by and between
the Senior Creditors pursuant to the Senior Subordination Agreement or the Junior Subordinated Agreement. This Agreement is intended solely to establish the relative rights and obligations of the Manager with respect to the Senior Creditors and to
establish the obligation of Company to comply with the requirements of Section 11. Nothing contained in this Agreement shall create any right, privilege or benefit for Company or persons not a party hereto, including, but not limited to, creditors
of the Company.



13. SUBROGATION. Subject to the
indefeasible payment in full in cash of all Senior Indebtedness and the termination of all lending commitments under the Senior Credit



4



---

Documents, the Manager shall be subrogated to the rights of the Senior Creditors to receive payments on, and proceeds of any collateral for, the Senior
Indebtedness until the Subordinated Indebtedness is paid in full.



14. CONFLICTS IN INTERPRETATION. In the event of any conflict between the provisions of this Agreement and any other agreement between the Company on the one hand and Manager on the other hand, relating to the incurrence or payment
of Management Fees or Actual Expenses, the terms of this Agreement shall control.



15. COUNTERPARTS. This Agreement may be executed in any number of counterparts, each of which shall be an original, but all of which shall constitute one and the same instrument.



[Remainder of this page intentionally left blank]



5



---

IN WITNESS WHEREOF, the parties hereto acting by and through their duly authorized officers have
executed this Management Fee Subordination Agreement as of the day and year first above written.



|                                                                                       |  |                                                  |  |                                     |  |                                |  |                          
|-------------------------------------------------------------------------------------- |  | ------------------------------------------------ |  | ----------------------------------- |  | ------------------------------ |  | -------------------------
|CHURCHILL CAPITAL PARTNERS IV, L.P. as Senior Note Purchaser and Junior Note Purchaser |  |                                                  |  | FLEET CAPITAL CORPORATION, as
Agent
|                                                                                       |  |                                                  |  |                                    
|By                                                                                     |  | Churchill Capital IV, L.L.C.,its General Partner |  |                                     |  |                                |  |                          
|By                                                                                     |  | Churchill Capital, Inc.its Managing Agent        |  |                                     |  | By                             |  | /s/ Brian Conole         
|                                                                                       |  |                                                  |  |                                     |  |                                |  | Its Senior Vice President
|By                                                                                     |  | /s/ Mark McDonald                                |  |                                     |  |                                |  |                          
|                                                                                       |  | Its Partner                                      |  |                                     |  |                                |  |                          
|                                                                                       |  |                                                  | 
|SPELL CAPITAL PARTNERS LLC, as
Manager                                                 |  |                                                  |  |                                     |  | PW EAGLE, INC., as the
Company
|                                                                                       |  |                                                  |  |                                    
|By                                                                                     |  | /s/ Dobson West                                  |  |                                     |  | By                             |  | /s/ Dobson West          
|                                                                                       |  | Its Chief Operating Officer                      |  |                                     |  |                                |  | Its Secretary            



[Signature Page to
Management Fee Subordination Agreement]