Normally you'd wrap up your resignation along with the appointment of the new BOD and officers (probably the buyers) at the same time that you executed the purchase and sale for your shares in the corporation. You wouldn't want to resign prior to execution of the deal, and then have it fall through for some reason.
It's up to you, but I'd consult with a business attorney in CA who handles these kinds of deals, as they will be able to help problem solve issues like this, as well as what your remedies would be in the event that the buyer defaulted on the agreement for any reason.
Legal disclaimer: The answer provided above is for general information purposes only and should not be relied on as specific legal advice. This answer does not form an attorney-client relationship. You should consult with an attorney of your choice to fully advise you about your legal rights and obligations.
Normally, you would first sell your shares to the buyer(s), and such sale would be approved by a board resolution signed by you. In the stock purchase agreement, there should be something about you agreeing to resign your position as director and officer contemporaneously with the sale. At that point, the new shareholder(s) would hold a meeting to elect the new board, and the new board would elect the new officers.
Our replies to Avvo questions should not be considered specific legal advice to any individual, and no attorney-client relationship is formed with you. Our aim is to provide general principles that may be useful to the Avvo community as a whole. You should seek individual legal advice pertaining to your specific factual situation, and the laws applicable to your jurisdiction.
Certainly don't want to be redundant, but your resignation would be part of the transaction by which you are selling your interest in the corporation to others. You would hold your positions to approve, as appropriate, the actions taken by the corporation for the sale, and would resign once the new shareholder(s) is in place, and can elect new directors, who in turn elect officers.
The transactional documents should address all of these steps. If you are responsible for preparation of the sale documents, you should consult an attorney locally that is familiar with this process. If your buyer is preparing the documents, you should have them reviewed carefully by a lawyer on 'your' side. You should also discuss the potential tax aspects with your lawyer or accountant, and consider what options may exist to minimize taxes that may result from your sale of the stock.
I agree with what has been said, and I would just add that you should only sign a resignation letter in advance if it states that it is contingent upon the Closing of the transaction (as “Closing” is defined in the transaction documents), and effective as of the Closing Date. It’s common to have all of the documents signed in advance and held in escrow by the lawyers until everything is finalized, but with the resignation I would take that additional precaution. Then you should make sure that the conditions to Closing in the documents all meet your needs (for example, a condition to closing would be that you have received your payment).
Disclaimer: This answer is provided for informational purposes only, does not constitute legal advice, and does not create an attorney-client relationship. Actual legal advice can only be provided after a direct consultation in which all of the relevant facts are considered before providing a response.