
    597 A.2d 696
    Murray S. ECKELL, W. Donald Sparks, Arthur Levy, David E. Auerbach, Joseph L. Monte, Jr., Alvin Moses, Ronald J. Klimas and Nicholas A. Emper, T/A Eckell, Sparks, Levy, Auerbach, Monte and Moses, a Partnership, Appellants, v. William B. WILSON.
    Superior Court of Pennsylvania.
    Argued June 11, 1991.
    Filed Oct. 4, 1991.
    
      Jeffrey A. Less, Philadelphia, for appellants.
    Perry F. DiCola, Media, for appellee.
    
      Before MONTEMURO, BECK and CERCONE, JJ.
   CERCONE, Judge:

This is an appeal from the order of the Court of Common Pleas of Delaware County granting appellee’s preliminary objections in the nature of a demurrer to appellants’ complaint. We reverse.

Appellants raise four issues for our consideration:

1. Whether a complaint seeking recovery pursuant to an oral agreement can be dismissed for lack of a writing, where that defense is raised on preliminary objections;
2. Whether a complaint, which alleges an oral agreement by a client to compensate a law firm based on the reasonable value of its services, with the final determination of that value to be based in part on whether the firm achieves a favorable result, fails to state a cause of action;
3. Whether a contingency fee agreement for representation in an equitable distribution proceeding, where the client had already obtained a divorce at the time that he retained the law firm, is unenforceable based upon Ethical Consideration 2-20 of the Code of Professional Responsibility or public policy;
4. Whether the lower court’s order granting the demurrer and dismissing the complaint with prejudice should be affirmed on any grounds?

Because we reverse on appellants’ second issue, we need not consider the other issues raised in this proceeding.

Appellants are partners in the Delaware County law firm of Eckell, Sparks, Levy, Auerbach, Monte and Moses. Appellee/client, William Wilson, retained the law firm to represent him in his equitable distribution suit against his former spouse. In their complaint, appellants averred that they entered into a fee arrangement with Wilson whereby Wilson would pay the firm based upon the reasonable value of the services rendered. The arrangement also included a provision for appellee to pay appellants a minimum fee based on hourly rates on account during the pendency of the litigation, with the final fee to be determined at the conclusion of the litigation based upon the reasonable value of their services, based in part on whether a favorable result was achieved. Complaint, paragraph 6. The complaint additionally averred that appellants rendered their professional services and were able to accomplish results favorable to Wilson. Complaint, paragraph 10. The attorneys allege that the settlement between appellee and his wife resulted in a net savings to appellee of at least $3.5 million. Complaint, paragraph 12.

Appellants further alleged that the law firm sent a bill to appellee in the amount of $150,000 at the conclusion of the litigation. This amount represents professional services rendered less amounts appellee already paid the firm. In to to, appellants alleged that appellee owes the firm $121,-498.90. Complaint, paragraphs 13, 14. Appellants also aver that, although the firm has demanded payment, appellee has refused such payment.

We note initially that our standard of review in an appeal from an order sustaining preliminary objections in the nature of a demurrer is the same as that which the trial court employs: all material facts set forth in the complaint as well as all inferences reasonably deducible therefrom are admitted as true for the purposes of review. Kyle v. McNamara & Criste, 506 Pa. 631, 634, 487 A.2d 814, 816 (1985). However, it does not admit conclusions of law. Wicks v. Milzoco Builders, Inc., 503 Pa. 614, 623, 470 A.2d 86, 91 (1983). The question presented by the demurrer is whether, on the facts averred, the law says with certainty that no recovery is possible. Kyle v. McNamara & Criste, 506 Pa. at 634, 487 A.2d at 816. A demurrer should be sustained only in cases where the plaintiff has clearly failed to state a claim on which relief may be granted. Philmar Mid-Atlantic, Inc. v. York Street Associates II, 389 Pa.Super. 297, 301, 566 A.2d 1253, 1254-55 (1989); Wicks v. Milzoco Builders, Inc., supra. A demurrer should not be sustained if there is any doubt as to whether the complaint adequately states a claim for relief under any theory of law. Id.

Appellants argue that the lower court erred in characterizing the fee arrangement in question as an illegal contingency fee agreement under the now repealed Code of Professional Responsibility. To the contrary, appellee/client argues that although most contingent fees are either calculated based on a formula or provide for a specific sum of money to be paid, this arrangement is also a contingency agreement because it is dependent on the success at trial. The lower court found that the agreement, as alleged, constituted a contingency fee. The trial judge reasoned:

If, as the plaintiffs [appellants] contend, there was an oral agreement which required payment based upon the degree of success encountered during the equitable distribution proceeding, then, by definition, the plaintiffs’ [appellants’] agreement with defendant [appellee] was contingent in nature.

Lower court opinion 12/17/90 at 3. The lower court then concluded that the agreement was void under Pa.R.Civ.P. Rule 202, 42 Pa.C.S.A. (rescinded April 4, 1990, effective July 1, 1990), and Code of Professional Responsibility, Ethical Considerations 2-19, 2-20, 42 Pa.C.S.A. (superseded by Rules of Professional Conduct, 42 Pa.C.S.A., effective April 1, 1988). Rule 202 and Ethical Considerations 2-19 and 2-20 were in effect at the time the purported fee arrangement was made.

Contingency agreements have been defined in various forms. The Pennsylvania Rules of Professional Conduct characterize a contingency fee in the following manner:

A fee may be contingent on the outcome of the matter for which the service is rendered, except in a manner in which a contingent fee is prohibited by paragraph (d) or other law.

Rule of Professional Conduct, Rule 1.5(c), 42 Pa.C.S.A. While caselaw defining a contingency fee is lacking in Pennsylvania, we find it instructive to consider the pronouncements of the Supreme Judicial Court of Massachusetts which has defined a contingent fee agreement between an attorney and client as,

an agreement express, or implied, for legal services ... under which compensation, contingent in whole or in part upon the successful accomplishment or disposition of the subject matter of the agreement, is to be in an amount which either is fixed or is to be determined under a formula____

New England Telephone & Telegraph Company v. Board of Assessors of Boston, 392 Mass. 865, 870-71, 468 N.E.2d 263, 266-67 (1984).

While ostensibly the fee arrangement in the instant case is contingent in nature, a closer analysis leads us to conclude otherwise. We are guided in this decision by the analyses of various courts of our sister states which have previously had occasion to construe the type of agreement at issue here. See, e.g., Muldoon v. West End Chevrolet, 338 Mass. 91, 153 N.E.2d 887 (1958); Marriage of Malec, 205 Ill.App.3d 273, 150 Ill.Dec. 207, 562 N.E.2d 1010 (1990); Salerno v. Salerno, 241 N.J.Super. 536, 575 A.2d 532 (1990); Head v. Head, 66 Md.App. 655, 505 A.2d 868 (1986). For example, in Muldoon, supra, an attorney sought to recover “fair and adequate compensation ” for legal services “and for the results achieved ” in connection with Federal income tax adjustments. The client contended that the fee arrangement was a wholly or partially contingent fee and unlawful under Treasury Department regulations. Muldoon, 338 Mass. at 93, 153 N.E.2d at 889 (emphasis added). The trial court in that case found that the attorney’s clients agreed to pay a retainer fee plus additional compensation for the attorney’s services in an amount that would constitute fair, adequate and just compensation for the services rendered. Id.

The Massachusetts Supreme Judicial Court affirmed on appeal holding:

Such an arrangement is a usual and proper arrangement between lawyer and client and means that the lawyer’s services, if they have any value at all, are to be paid for in some amount in any event and that their fair market value is to be computed, after the services have been rendered, by an appraisal of the services in the light of all relevant circumstances. Certainly, ... the importance, size and difficulty of the matter involved, and the attorney’s success in dealing with them, are among the relevant considerations.

Id. at 95, 153 N.E.2d at 891 (citations omitted, emphasis added).

A more recent Illinois decision also concluded that a fee arrangement which determines the final fee based on the outcome of the case is not a contingency fee. In Marriage of Malec, supra, an attorney and his former partner entered into an agreement with John Malee, the petitioner, to represent Malec in his marriage dissolution. Marriage of Malec, 205 Ill.App.3d at 278, 150 Ill.Dec. at 211, 562 N.E.2d at 1014. The attorneys required a retainer fee and told Malee that the remainder of the fees would be settled, based on performance, at the end of the case. There was no written contract memorializing the agreement. Id. The petitioner/client argued that an enhanced fee or one that is based on results achieved, is a contingent fee. The Illinois court disagreed finding instead that the results obtained in litigation are a factor to be considered as a guide in determining reasonableness of the fee. Id. at 288, 150 Ill.Dec. at 217-18, 562 N.E.2d at 1020-21. The Malee court held that consideration of the reasonableness of a fee after litigation does not convert the fee into a contingency fee. Id. at 1020, 150 Ill.Dec. at 218, 562 N.E.2d at 1021.

A recent New Jersey decision also discussed the type of arrangement at issue here. In Salerno v. Salerno, supra, an attorney entered into a fee arrangement in a domestic action which recited the following:

1. you hereby agree to pay our firm a non-refundable minimum retainer fee of $2,500. The minimum fee will be credited against the legal services and court costs and disbursements in your matter as they accrue. If the services rendered by me are completed in less than — hours, I will retain the full retainer as a minimum fee.
2. The final billing is based on four factors: (1) the basic hourly rate (b) the result accomplished; (c) the amount in controversy; and (d) our experience and ability, all of which will be taken into consideration when the final bill is issued and none of which is solely determinative of the fee.

Id. at 541, 575 A.2d at 535. The New Jersey court held that although there was no rule which prohibited and attorney charge for an hourly rate and also an additional charge for the same service based on other factors, the additional charge resembled a contingent fee. The court therefore found the agreement invalid because the attorney failed to reduce the agreement to a writing and to detail an exact formulation to calculate the additional charge. Id. at 539, 575 A.2d at 534; New Jersey Rule of Professional Conduct, Rule 1.5(d)(1); N.J.Court Rule 1:21-7A.

Finally, in Head v. Head, supra, 66 Md.App. 655, 505 A.2d 868, the Maryland Court of Special Appeals had occasion to review a similar fee arrangement. In that case, appellee/husband petitioned the court for reasonable attorneys fees in defending against his wife’s attack on their antenuptial agreement. Husband’s law firm did not bill him for the additional fee, but looked to the court for a determination. An expert who testified at trial set the fee at $125,000. The trial court adopted this calculation. In a lengthy discussion, the Court of Special Appeals determined that an agreement based upon the reasonable value of the services provided by a lawyer was not a contingency fee. The court reasoned:

[T]he fee was not directly related by percentage or formula to the amount recovered or protected. Additionally, it failed to meet the generally accepted twofold purpose of a contingent fee. Not only could the parties clearly afford to retain the services of counsel on a fixed fee or hourly rate, but the successful resolution of the claim ... would not produce a res out of which the fee could be paid. There could be no res produced. The funds at issue were already in possession. It was the shielding of those funds from appellant’s claim that was at issue.

Id. at 668-69, 505 A.2d at 875.

After carefully considering the facts of the instant case, we agree with the majority of courts which concluded that an agreement which fixes a final fee based on the value of services rendered through the representation is a proper method of fixing a fee and is not a contingent fee in its commonly used meaning. In this situation, the fee is not truly contingent on the outcome of the case because the attorneys are paid regardless of the outcome of the litigation. In essence, they are exacting a fee based on their performance during the course of the litigation. A contingency fee agreement carries a risk that an attorney will not be paid if the outcome of the litigation is unsuccessful. No such risk is found here. Our Rules of Professional Conduct support such a result. The Pennsylvania Rules of Professional Conduct, Rule 1.5 states in pertinent part:

(a) A lawyer shall not enter into a fee arrangement for, charge, or collect an illegal or clearly excessive fee. The factors to be considered in determining the propriety of a fee include the following:
(1) whether the fee is fixed or contingent;
(2) the time and labor required, the novelty and difficulty of the questions involved, and the skill requisite to perform the legal services properly;
(3) the likelihood, if apparent to the client, that the acceptance of the particular employment will preclude other employment by the lawyer;
(4) the fee customarily charged in the locality for similar legal services;
(5) the amount involved and the results obtained;
(6) the time limitations imposed by the client or by the circumstances;
(7) the nature and the length of the professional relationship with the client; and
(8) the experience, reputation, and ability of the lawyer or lawyers performing the services.

Pa.R.Prof.Conduct, Rule 1.5; Code of Professional Responsibility, DR 2-106(B). We decline to follow the New Jersey court decision in Salerno, supra. While this type of fee arrangement is seemingly characteristic of a contingency agreement, the New Jersey court failed to recognize that the agreement merely seeks a quantum meruit fee based on the reasonable value of the services rendered. We therefore, vacate the order granting appellee’s preliminary objections and reinstate appellant’s complaint.

Order of November 19, 1990 vacated; complaint reinstated. Remanded for proceedings consistent with this memorandum; jurisdiction relinquished. 
      
      . Appellee also argues that appellants sent a letter to appellee confirming the agreement between them. He argues that the parol evidence rule bars appellants from alleging a prior oral agreement which contradicts the terms of the writing. The contents of the writing were attached to the pleadings as part of an affidavit.
      Our standard of review precludes us from analyzing the letter. It is well-settled that a demurrer cannot be a "speaking demurrer" and cannot be used to supply a fact missing in the complaint. Hall v. Goodman, 310 Pa.Super. 465, 477, 456 A.2d 1029, 1035, (1983). An exception exists to allow a defendant to attach a copy of a written agreement where the plaintiff alleges an agreement based on a writing. No exception exists, however, when an oral agreement is alleged. Martin v. Commonwealth, Department of Transportation, 124 Pa. Commw. 625, 629, 556 A.2d 969, 971 (1989). Here, appellants have alleged that the fee agreement was oral. We therefore, cannot consider the affidavit which states the terms of the letter contradicting appellants’ allegation of an oral agreement. An issue of this type is properly raised in a motion for summary judgment.
     
      
      . Rule 202 provided that agreements between attorney and client relating to compensation wholly or partly on a contingent basis shall be in writing.
     
      
      . Code of Professional Responsibility, Ethical Consideration 2-19 provided "it is usually beneficial to reduce to writing the understanding of the parties regarding the fee, particularly where it is contingent.” Code of Professional Responsibility, Ethical Consideration 2-20 provided that because of the human relationships involved and the unique character of the proceedings, contingent fee arrangements in domestic relation cases are rarely justified. However, the ethical considerations are aspirational in character and represent the objectives toward which every member of the profession should strive. Code of Professional responsibility, Preamble and Preliminary Statement, 42 Pa.C.S.A. (rescinded effective April 1, 1988). They are not mandatory laws.
      The trial judge also found that the conduct of the appellants may have violated Rule of Professional Conduct, Rule 1.5(c), 42 Pa.C.S.A. for failing to set forth a contingency fee agreement in writing. We note that because the purported agreement was entered into, in 1984, while the Code of Professional responsibility was in effect, the Code governs the present case. Rules of Professional Conduct, Publisher’s Note, 42 Pa.C.S.A. (professional misconduct occurring on or before March 31, 1988 is governed by the Code of Professional Responsibility).
     
      
      . The Illinois Court of Appeals held that the fee arrangement was not a contingency fee because it was based upon the reasonableness of the services rendered. However, it additionally held that a subsequent agreement between the petitioner and one of the lawyers permitting a $1 million fee if certain particularized results were achieved in the underlying litigation, transformed what was otherwise a legitimate fee arrangement into a contingency fee. Id.
      
     
      
      . Since we find that the arrangement at issue here is not a contingency fee arrangement, it is not subject to Pa.R.Civ.P. Rule 202, 42 Pa.C.S.A. (rescinded), which requires contingent fee agreements be set forth in a writing, or Code of Professional Responsibility, EC 2-20, 42 Pa.C.S.A., which disapproves of contingent fee agreements in domestic relations actions.
     
      
      . While the current Rules of Professional Conduct were not in effect at the time of this transaction, the rules are helpful in determining the current state of the law in this Commonwealth. Moreover, we believe that the Rules of Professional Conduct would require the same result. The Rules only require a writing where an attorney enters into a contingency fee agreement with the client. Pa.Rules of Professional Conduct, Rule 1.5(c), 42 Pa.C.S.A.
      However, we alert appellants to the exigency of a writing to confirm the fee arrangement with the client. In this regard, writings avoid misunderstandings regarding the fee and the methods by which it is determined. Pa.Rules of Professional Conduct, Rule 1.5, comment, 42 Pa.C.S.A. (a written statement concerning the fee reduces the possibility of misunderstanding).
     
      
      . It is incumbent upon the trial court to determine whether the fee which counsel exacts is reasonable in light of all factors enumerated . in Rule of Professional Responsibility, Rule 1.5, 42 Pa.C.S.A., or in the Code of Professional Conduct DR 2-106, 42 Pa.C.S.A. If the court does not scrutinize the fee under a reasonableness standard, a danger exists that a client may be subject to an attorney's overreaching because the attorney would be permitted to set the fee arbitrarily and unilaterally.
     