Exhibit 10.4

THE DIME BANK

CHANGE IN CONTROL SEVERANCE AGREEMENT

This Agreement is effective April 7, 2005, and is entered into among The Dime Bank (the Bank), a Pennsylvania Banking
Corporation, the principal offices for which are located at 820 Church Street, Honesdale, PA 18431 (the Bank), Dimeco, Inc., a Bank Holding Company (the Holding Company) located at the same address, and Gary C.
Beilman (Executive).

Whereas, the Bank and the Holding Company recognize the substantial contribution Executive has made
to the Bank and the Holding Company, and the Bank and the Holding Company wish to protect the Executives position with the Bank for the period provided in this Agreement, and in the event of a Change in Control of the Bank and/or Holding
Company, for the two (2) year period thereafter; and

Whereas, Executive has agreed to serve in the employ of the Bank in the capacity
of Chief Financial Officer;

Now, therefore, the parties agree as follows:



|1. | Term of Agreement.
|-- | ------------------

This Agreement shall
continue in effect for the thirty-six-month period beginning as of the date hereof, and may be extended by the Board of Directors of the Bank (the Board) for additional one-year terms as set forth below.



|2. | Extension by Board.
|-- | -------------------

Commencing on third
anniversary hereof, and continuing annually thereafter, the Board may extend the term of this Agreement for additional one-year periods. The Board will review the Agreement and the Executives performance annually beginning in advance of the
third anniversary hereof for purposes of determining whether to extend the term, and will include the review and extension or non-extension in the minutes of the next-to-occur meeting of the Board.



|3. | Change in Control Followed by Termination of Employment.
|-- | --------------------------------------------------------

Upon occurrence of a Change in Control of the Bank and/or Holding Company followed by termination of Executives employment within two years following the Change in Control, the provisions of Section 5 shall
apply unless such termination is because of death, disability, retirement, Termination for Cause or the Executives voluntary resignation not covered by subparts (i) through (iv) below. Executive shall have the right to elect to
voluntarily terminate her employment within two years following a Change in Control in the event that Executive suffers any of the following: (i) any material loss of title, office, or significant authority or responsibility, (ii) any
material reduction in annual compensation or benefits in excess of ten percent (10%) of the monetary value of her current compensation and benefits, (iii) relocation of Executives principal office by more than 30 miles from its
location immediately subsequent to the Change in Control, or (iv) failure by the Bank to obtain satisfactory agreement from any successor to assume the obligations and liabilities of this Agreement.



- Page 1 -



---

|4. | Definitions.
|-- | ------------

(A) Change in
Control. A Change in Control of the Bank or Holding Company shall mean an event of a nature that: (i) would be required to be reported in response to Item 1 of the Current Report on Form 8-K, as in effect on the date
hereof, pursuant to Section 13 or 15(d) of the Securities Exchange Act of 1934, as amended (the Exchange Act); or (ii) results in a Change in Control of the Bank or the Holding Company within the meaning of the Federal Deposit
Insurance Act; or (iii) without limitation such a Change in Control shall be deemed to have occurred at such time as (a) any person (as the term is used in Sections 13(d) and 14(d) of the Exchange Act) is or becomes the
beneficial owner (as defined in Rule 13d-3 under the Exchange Act), directly or indirectly, of voting securities of the Bank or the Holding Company representing 25% or more of the Banks or the Holding Companys outstanding
voting securities or right to acquire such securities except for any voting securities of the Bank purchased by the Holding Company and any voting securities purchased by any employee benefit plan of the Bank or the Holding Company, or
(b) individuals who constitute the Board on the date hereof (the Incumbent Board) cease for any reason to constitute at least a majority thereof, provided that any person becoming a director subsequent to the date hereof whose
election was approved by a vote of at least three-quarters of the Directors comprising the Incumbent Board, or whose nomination for election by the Holding Companys stockholders was approved by a Nominating Committee solely composed of members
which are Incumbent Board members, shall be, for purposes of this clause (b), considered as though he were a member of the Incumbent Board, or (c) a plan of reorganization, merger, consolidation, sale of all or substantially all the assets of
the Bank or the Holding Company or similar transaction occurs or is effectuated in which the Bank or Holding Company is not the resulting entity.

(B) Termination for Cause. Termination for Cause shall mean termination because of Executives personal dishonesty, incompetence, willful misconduct, conduct damaging the reputation of the Bank or the Holding
Company, any breach of fiduciary duty involving personal profit, intentional failure to perform stated duties, willful violation of any law, rule, or regulation (other than traffic violations or similar offenses) or final cease and desist order, or
material breach of any provision of this Agreement. Notwithstanding the foregoing, Executive shall not be deemed to have been Terminated for Cause unless and until there shall have been delivered to Executive a Notice of Termination which shall
include a copy of a resolution duly adopted by the affirmative vote of not less than a majority of the members of the Board at a meeting of the Board called and held for that purpose (after reasonable notice to Executive and an opportunity for
Executive, together with counsel, to be heard before the Board), finding that in the good faith opinion of the Board, Executive was guilty of conduct justifying Termination for Cause and specifying the particulars thereof in detail. Executive shall
not have the right to receive compensation or other benefits for any period after the Date of Termination for Cause. During the period beginning on the date of the Notice of Termination for Cause pursuant to Section 6 hereof through the Date of
Termination for Cause, stock options and related limited rights granted to Executive under any stock option plan shall not be exercisable nor shall any unvested awards granted to Executive under any stock benefit plan of the Bank, the



- Page 2 -



---

Holding Company, or any subsidiary or affiliate thereof, vest. At the Date of Termination for Cause, such stock options and related limited rights and such
unvested awards shall become null and void and shall not be exercisable by or delivered to Executive at any time subsequent to such Date of Termination for Cause.



|5. | Termination Benefits.
|-- | ---------------------

(A) Sum
Payable. Upon the occurrence of a Change in Control, followed by the termination of the Executives employment within two years following the Change in Control due to (1) Executives termination as outlined above in subparts
(i), (ii), (iii) or (iv) of Section 3, or (2) Executives dismissal, unless such dismissal is due to Termination for Cause, the Bank and the Holding Company shall pay Executive, or in the event of her subsequent death, her
beneficiary or beneficiaries, or her estate, as the case may be, a sum equal to three (3) times Executives average annual compensation for the five most recent taxable years that Executive has been employed by the Bank or such lesser
number of years in the event that Executive shall have been employed by the Bank for less than five years. Such average annual compensation shall include base salary, commissions, bonuses, any other cash compensation, contributions or accruals on
behalf of Executive to any pension and/or profit sharing plan, director or committee fees and fringe benefits paid or to be paid to the Executive in any such year and payment of any expense items without accountability or business purpose or that do
not meet the Internal Revenue Service requirements for deductibility by the Bank; provided, however, that any payment under this provision and subsection 5(B) below shall not exceed three (3) times the Executives average annual
compensation. At the election of Executive, which election is to be made prior to a Change in Control, such payment shall be made in a lump sum as of Executives Date of Termination. In the event that no election is made, payment to Executive
will be made on a monthly basis in approximately equal installments over the ensuing thirty-six (36) months.

(B) Life and
Medical Insurance Coverage. Upon the occurrence of a Change in Control of the Bank or the Holding Company followed by Executives voluntary (as outlined above in subparts (i), (ii), (iii) or (iv) of Section 3) or
involuntary termination of employment within two years following the Change in Control, other than Termination for Cause, the Bank shall cause to be continued all benefit coverages provided under the Banks (or its successors) employee
welfare benefit plans and programs, including but not limited to life, medical and dental insurance coverage substantially equivalent to the coverage maintained by the Bank or Holding Company for Executive prior to his severance, except to the
extent such coverage may be changed in its application to all Bank or Holding Company employees on a nondiscriminatory basis. Such coverage and payments shall cease upon the expiration of thirty-six (36) full calendar months following the Date
of Termination. Notwithstanding the foregoing, if prior to the expiration of thirty-six (36) calendar months following the Date of Termination, the Executive becomes enrolled in another group plan or policy providing for medical and/or dental
benefits, then the foregoing medical and/or dental coverage shall terminate on the date that such enrollment becomes effective. Upon the expiration of thirty-six (36) full calendar months following the Date of Termination, and if the Executive
has not become enrolled in another group plan or policy providing for medical and/or dental benefits prior to such time, Executive, and if applicable, his dependents, will be eligible to elect COBRA continuation coverage in accordance with the
then-in-effect terms and conditions of the available coverages for employee welfare benefit plans.



- Page 3 -



---

(C) Section 280G. Notwithstanding the preceding paragraphs of this Section 5, in
no event shall the aggregate payments or benefits to be made or afforded to Executive under said paragraphs (the Termination Benefits) constitute an excess parachute payment under Section 280G of the Code or any
successor thereto, and in order to avoid such a result, Termination Benefits will be reduced, if necessary, to an amount (the Non-Triggering Amount), the value of which is one dollar ($1.00) less than an amount equal to three
(3) times Executives base amount, as determined in accordance with said Section 280G. The allocation of the reduction required hereby among the Termination Benefits provided by the preceding paragraphs of this
Section 5 shall be determined by Executive.



|6. | Notice of Termination.
|-- | ----------------------

(A)
Form. Any purported termination by the Bank or by Executive in connection with a Change in Control shall be communicated by a written Notice of Termination which shall include the specific termination provision in this
Agreement relied upon and shall set forth in reasonable detail the facts and circumstances claimed to provide a basis for termination of Executives employment under the provision so indicated.

(B) Date of Termination. Date of Termination shall mean the date specified in the Notice of Termination (which, in the instance
of Termination for Cause, shall not be less than thirty (30) days from the date such Notice of Termination is given); provided, however, that if a dispute regarding the Executives termination exists, the Date of Termination
shall be determined in accordance with Section 6(C) of this Agreement.

(C) Dispute. If, within thirty (30) days
after any Notice of Termination is given, the party receiving such Notice of Termination notifies the other party that a dispute exists concerning the termination, except upon the occurrence of a Change in Control and voluntary termination by the
Executive in which case the Date of Termination shall be the date specified in the Notice, the Date of Termination shall be the date on which the dispute is finally determined, either by mutual written agreement of the parties, by a binding
arbitration award, or by a final judgment, order or decree of a court of competent jurisdiction (the time for appeal therefrom having expired and no appeal having been perfected) and provided further that the Date of Termination shall be extended by
a notice of dispute only if such notice is given in good faith and the party giving such notice pursues the resolution of such dispute with reasonable diligence. Notwithstanding the pendency of any such dispute in connection with a Change in
Control, in the event that the Executive is terminated for reasons other than Termination for Cause, the Bank will continue to pay Executive the payments and benefits due under this Agreement in effect when the notice giving rise to the dispute was
given (including, but not limited to, her current annual salary) and continue her as a participant in all compensation, benefit, and insurance plans in which she was participating when the notice of dispute was given, until the earlier of:
(1) the resolution of the dispute in accordance with this Agreement; or (2) the expiration of the remaining term of this Agreement as determined as of the Date of Termination. Amounts paid under this Section 6(C) are in addition to
all other amounts due under this Agreement and shall not be offset against or reduce any other amounts due under this Agreement.



- Page 4 -



---

|7. | Source of Payments.
|-- | -------------------

It is intended by the
parties hereto that all payments provided in this Agreement shall be paid in cash or check from the general funds of the Bank. Further, the Holding Company guarantees such payment and provision of all amounts and benefits due hereunder to Executive.



|8. | Effect on Prior Agreements and Existing Benefit Plans.
|-- | ------------------------------------------------------

This agreement contains the entire understanding between the parties hereto and supersedes any prior agreement between the Bank and Executive, except that this Agreement shall not affect or operate to reduce any
benefit or compensation inuring to Executive of a kind elsewhere provided. No provision of this Agreement shall be interpreted to mean that Executive is subject to receiving fewer benefits than those available to her without reference to this
Agreement. Nothing in this Agreement shall confer upon Executive the right to continue in the employ of Bank or shall impose on the Bank any obligation to employ or retain Executive in its employ for any period.



|9. | No Attachment.
|-- | --------------

(A) Except as required by
law, no right to receive payments under this Agreement shall be subject to anticipation, commutation, alienation, sale assignment, encumbrance, charge, pledge, or hypothecation, or to execution, attachment, levy, or similar process or assignment by
operation of law, and any attempt, voluntary or involuntary, to affect any such action shall be null, void, and of no effect.

(B) This
Agreement shall be binding upon, and inure to the benefit of, Executive, the Bank, and their respective successors and assigns.



|10. | Modification and Waiver.
|--- | ------------------------

(A) This Agreement
may not be modified or amended except by an instrument in writing signed by the parties hereto.

(B) No term or condition of this Agreement
shall be deemed to have been waived, nor shall there be any estoppel against the enforcement of any provision of this Agreement, except by written instrument of the party charged with such waiver or estoppel. No such written waiver shall be deemed a
continuing waiver unless specifically stated therein, and each such waiver shall operate only as to the specific term or condition waived and shall not constitute a waiver of such term or condition for the future or as to any act other than that
specifically waived.



- Page 5 -



---

|11. | Required Regulatory Provisions.
|--- | -------------------------------

(A) The
Board of Directors may terminate Executives employment at any time, but any termination by the Board of Directors, other than Termination for Cause, shall not prejudice Executives right to compensation or other benefits under this
Agreement. Executive shall not have the right to receive compensation or other benefits for any period after Termination for Cause as defined in Section 4 above.

(B) If Executive is suspended from office and/or temporarily prohibited from participating in the conduct of the Banks affairs by a notice served under Section 8(e)(3) or 8(g)(1) of the Federal Deposit
Insurance Act (12 U.S.C. §1818(e)(3) or (g)(1)), the Banks obligations under this contract shall be suspended as of the date of service, unless stayed by appropriate proceedings. If the charges in the notice are dismissed, the Bank will
(i) pay Executive all or part of the compensation withheld while the contract obligations were suspended and (ii) reinstate any of the obligations which were suspended.

(C) If Executive is removed and/or permanently prohibited from participating in the conduct of the Banks affairs by an order issued under
Section 8(e)(4) or 8(g)(l) of the Federal Deposit Insurance Act (12 U.S.C. §1818(e)(4) or (g)(1)), all obligations of the Bank under this contract shall terminate as of the effective date of the order, but vested rights of the contracting
parties shall not be affected.

(D) If the Bank is in default as defined in Section 3(x)(1) of the Federal Deposit Insurance Act, all
obligations of the Bank under this contract shall terminate as of the date of default, but this paragraph shall not affect any vested rights of the contracting parties.

(E) Any payments made to Executive pursuant to this Agreement, or otherwise, are subject to and conditioned upon compliance with 12 U.S.C. §1828(k) and any rules and regulations promulgated thereunder.



|12. | Reinstatement of Benefits Under Section 11(B).
|--- | ----------------------------------------------

In the event Executive is suspended and/or temporarily prohibited from participating in the conduct of the Banks affairs by a notice described in Section 11(B) hereof (the Notice) during the term of this Agreement and
a Change in Control, as defined herein, occurs, the Bank will assume its obligation to pay and Executive will be entitled to receive all of the termination benefits provided for under Section 5 of this Agreement upon receipt of a dismissal of
charges in the Notice.



|13. | Severability.
|--- | -------------

If, for any reason, any
provision of this Agreement, or any part of any provision, is held invalid, such invalidity shall not affect any other provision of this Agreement or any part of such provision not held so invalid, and each such other provision and part thereof
shall to the full extent consistent with law continue in full force and effect.



- Page 6 -



---

|14. | Headings for Reference Only.
|--- | ----------------------------

The headings
of sections and paragraphs herein are included solely for convenience of reference and shall not control the meaning or interpretation of any of the provisions of this Agreement.



|15. | Governing Law.
|--- | --------------

The validity,
interpretation, performance, and enforcement of this Agreement shall be governed by the laws of the Commonwealth of Pennsylvania, but only to the extent not preempted by Federal law.



|16. | Arbitration.
|--- | ------------

Any dispute or controversy
arising under or in connection with this Agreement shall be settled exclusively by arbitration, conducted before a panel of three arbitrators sitting in a location selected by Executive within fifty (50) miles from the location of the
Banks main office, in accordance with the rules of the American Arbitration Association then in effect. Judgment may be entered on the arbitrators award in any court having jurisdiction; provided, however, that Executive shall be
entitled to seek specific performance of her right to be paid until the Date of Termination during the pendency of any dispute or controversy arising under or in connection with this Agreement.



|17. | Payment of Costs and Legal Fees.
|--- | --------------------------------

All
reasonable costs and legal fees paid or incurred by Executive pursuant to any dispute or question of interpretation relating to this Agreement shall be paid or reimbursed by the Bank (which payments are guaranteed by the Holding Company pursuant to
Section 7 hereof) if Executive is successful pursuant to a legal judgment, arbitration or settlement.



|18. | Indemnification.
|--- | ----------------

(A) The Bank shall provide
Executive (including her heirs, executors and administrators) with coverage under a standard directors and officers liability insurance policy at its expense and shall indemnify Executive (and her heirs, executors and administrators) to
the fullest extent permitted under Federal law against all expenses and liabilities reasonably incurred by her in connection with or arising out of any action, suit or proceeding in which she may be involved by reason of her having been a director
or officer of the Bank (whether or not she continues to be a director or officer at the time of incurring such expenses or liabilities), such expenses and liabilities to include, but not be limited to, judgments, court costs and attorneys fees
and the cost of reasonable settlements.

(B) Any payments made to Executive pursuant to this Section are subject to and conditioned upon
compliance with 12 C.F.R. §545.121 and any rules or regulations promulgated thereunder.



- Page 7 -



---

|19. | Successor to the Bank
|--- | ---------------------

The Bank shall
require any successor or assignee, whether direct or indirect, by purchase, merger, consolidation or otherwise, to all or substantially all of the business assets of the Bank, expressly and unconditionally to assume and agree to perform the
Banks obligations under this Agreement. Accordingly, any reference herein to the Bank or the Holding Company whereby a performance obligation toward the Executive is created, such obligation shall apply to any such successor entity.



|20. | Date Signed: April 7, 2005
|--- | --------------------------



|                            |  |  |  |                                                    
|--------------------------- |  |  |  | ---------------------------------------------------
|ATTEST:                     |  |  |  | THE DIME BANK                                      
|                            |  | 
|/s/ Linda S. Tallman        |  |  |  | /s/ William E. Schwarz                             
|Linda S. Tallman, Secretary |  |  |  | William E. Schwarz Chairman of the
Board           
|                            |  | 
|ATTEST:                     |  |  |  | DIMECO, INC.(Guarantor)                            
|                            |  | 
|/s/ John F. Spall           |  |  |  | /s/ William E. Schwarz                             
|John F. Spall, Secretary    |  |  |  | William E. Schwarz Chairman of the
Board           
|                            |  | 
|ATTEST:                     |  |  |  | FOR THE BOARD OF DIRECTORS                         
|                            |  | 
|/s/ Linda S. Tallman        |  |  |  | /s/ John S. Kiesendahl                             
|Linda S. Tallman, Secretary |  |  |  | John S. Kiesendahl Chairman, Compensation
Committee
|                            |  | 
|WITNESS:                    |  |  |  | EXECUTIVE                                          
|                            |  | 
|/s/ Barbara J. Genzlinger   |  |  |  | /s/ Gary C. Beilman                                
|                            |  |  |  | Gary C. Beilman                                    



- Page 8 -