
530 So.2d 136 (1988)
Mark D. WHOLEY, M.D.
v.
CAL-MAINE FOODS, INC., a Corporation, and Cal-Maine Eggs, Inc., a Corporation.
John A. Rodgers
v.
Cal-Maine Foods, Inc., a Corporation, and Cal-Maine Eggs, Inc., a Corporation.
Nos. 57804, 57805.
Supreme Court of Mississippi.
July 27, 1988.
Rehearing Denied September 21, 1988.
*137 Don O. Rogers, Wilbourn, Rogers & Scarborough, Meridian, George E. Fowkes, Fowkes & Birmingham, Oakmont, Pa., for appellants.
Frank T. Moore, Jr., James Neeld, III, Wells, Moore, Simmons, Subblefield & Neeld, Jackson, for appellees.
Before DAN M. LEE, P.J., and SULLIVAN and ZUCCARO, JJ.
ZUCCARO, Justice, for the Court:
On September 22, 1986, the Chancery Court of Hinds County entered two summary judgments in favor of Cal-Maine, dismissing separately the actions of Wholey and Rodgers. These actions were at trial, and now on appeal, companion cases raising identical issues, and as a consequence will be consolidated. After due consideration, we reverse and remand.

FACTS
Appellants were two of many limited partners in National Farming Program/1973, a limited partnership in which appellees were the general managing partner. The partnership term was for five years, beginning on June 11, 1973, and ending on December 31, 1978. Each of appellants' interest in National Farming Program/1973 consisted of a $5,000 investment out of a total of $6,000,000 of limited partnership interest. The limited partnership during its term was economically unsuccessful and by August, 1977, Wholey and Rodgers, as well as the other limited partners, were made aware through a regularly transmitted status report letter that the partnership was experiencing net losses and that their capital investment had diminished with little or no hope of obtaining any refund of said investment. In December, 1978, the limited partnership was dissolved, and by a letter dated February 28, 1979, the limited partners were informed that there would be no return of capital.
On April 2, 1986, Wholey and Rodgers separately filed complaints against appellees in the Chancery Court of Hinds County alleging that appellees, as general managing partners, by misappropriations from the partnership and through self dealing, made hidden profits for itself and concealed those profits from the limited partners, which led to the demise of National Farming/1973. On this basis, appellants contended that appellees breached the fiduciary duty placed upon it to act in good faith and with integrity concerning partnership affairs. In furtherance of this contention, appellants asserted the fact that appellees *138 charged the limited partnership management fees as follows:


    1973       $   21,371.00
    1974       $  990,457.00
    1975       $1,009,408.00
    1976       $1,087,662.00
    1977       $1,084,440.00
    1978       $1,072,516.00

Other examples of overreaching were alleged in furtherance of the claims.
On June 12, 1986, Cal-Maine filed two motions for summary judgment based solely on its contention that appellants' complaints were barred by the six-year statute of limitations set forth in § 15-1-49 of the Mississippi Code of 1972. The chancellor granted Cal-Maine's motion not only upon the basis that Wholey and Rodgers' claims were barred by the six-year statute of limitations, but upon the additional basis that the doctrine of res judicata acted so as to bar both suits. Prior to the lower court's order granting Cal-Maine's motions for summary judgment, the issue of res judicata had not been raised in the pleadings, discovery, or in the motion itself. Wholey and Rodgers appeal the lower court's determination, each assigning three errors as follows.

I. DID THE TRIAL COURT ERR BY GRANTING SUMMARY JUDGMENT FOR CAL-MAINE ON THE BASIS OF RES JUDICATA?
As stated above, one of the reasons for the lower court's granting of Cal-Maine's motions for summary judgment was res judicata. The lower court's determination that res judicata precluded appellants' actions were based upon the fact that appellants had filed on March 3, 1983 an almost identical actions against Cal-Maine in the Chancery Court of Hinds County. These matters were never brought to trial, and on March 13, 1986, Chancery Judge Paul G. Alexander dismissed both actions for failure to prosecute. Subsequently, on April 2, 1986, appellants filed the present actions, which Chancellor Stuart Robinson dismissed in part on the basis that Chancellor Alexander's dismissal of appellants' previously filed suits for failure to prosecute was res judicata to the present actions. A critical fact that must be noted is that none of the pleadings, discovery, motions, etc. reflected by the records in either case mention the prior filing by Wholey and Rodgers, their subsequent dismissal by Chancellor Alexander, or that such might be res judicata. Indeed, the first point in the record at which res judicata is raised is in Chancellor Robinson's order dismissing both cases.
Rule 8(c) of the Mississippi Rules of Civil Procedure provides that:
Affirmative Defenses. In pleading to a preceding pleading, a party shall set forth affirmatively accord and satisfaction, arbitration and award, assumption of risk, contributory negligence, discharge in bankruptcy, duress, estoppel, failure of consideration, fraud, illegality, injury by fellow servant, laches, license, payment, release, res judicata, statute of frauds, statute of limitations, waiver, and any other matter constituting an avoidance or affirmative defense. When a party has mistakenly designated a defense as a counterclaim or a counterclaim as a defense, the court on terms, if justice so requires, shall treat the pleading as if there had been proper designation.
As is readily apparent from the plain language of the above rule, if a party intends to rely on one of the above enumerated defenses, including res judicata, he must affirmatively plead it. Affirmative defenses neither pleaded nor tried by consent are deemed waived. Bell v. First Columbus National Bank, 493 So.2d 964, 968 (Miss. 1986). Cal-Maine did not set forth res judicata in its answer as an affirmative defense, as is required by Rule 8(c). The question thus becomes whether a trial court, in this instance the Chancery Court of Hinds County, may raise res judicata on its own motion or otherwise utilize such when this defense has not been affirmatively plead.
In Glass v. Armstrong, 330 So.2d 57 (Fla.App. 1976), it was held that a trial court is not authorized to take judicial notice of cases pending or previously disposed of in the same court but outside the record in the case before it. Glass at 58 quoting Kostecos v. Johnson, 85 So.2d 594 (Fla. *139 1956). Further, the Glass case held that res judicata may not be first raised on a motion to dismiss, as in the present case, for the reason that res judicata is an affirmative defense requiring both pleading and proof. 330 So.2d at 58. Res judicata is an affirmative defense which may not be raised on motion to dismiss unless allegations of a prior pleading in the case demonstrates its existence. Livingston v. Spires, 481 So.2d 87 (Fla.App. 1 Dist. 1986).
Neither record reveals the manner in which the prior dismissal of both appellants' cases was brought to Chancellor Robinson's attention. However, whether the chancellor took judicial notice of the prior dismissals, or whether they were brought to his attention during argument concerning Cal-Maine's summary judgment motions is irrelevant. Since res judicata was not affirmatively plead by Cal-Maine it was error for the lower court to grant summary judgment on this basis.

II. DID THE TRIAL COURT ERR IN GRANTING SUMMARY JUDGMENT FOR CAL-MAINE BY APPLYING SECTION 15-1-49 OF THE MISSISSIPPI CODE OF 1972?
The lower court, in its separate orders granting Cal-Maine's motions for summary judgment, determined that appellants' actions against Cal-Maine had "clearly manifested" themselves at least by February 28, 1979, which the trial court found to be the date that appellants became completely aware that their investment was gone and that they would receive no return. The lower court then concluded that the actions, which were filed on April 2, 1986, were barred by the general six-year statute of limitations provided for in § 15-1-49 of the Mississippi Code of 1972. Appellants argued below, and now on appeal, that the present case is controlled not by the six-year statute of limitations found in § 15-1-49, but instead by the ten-year limitations period found in § 15-1-39. In this regard, § 15-1-39 provides that:
Limitations applicable to actions involving certain trusts.

Bills for relief, in case of the existence of a trust not cognizable by the courts of common law and in all other cases not herein provided for, shall be filed within ten years after the cause thereof shall accrue and not after, saving, however, to all persons under disability of infancy or unsoundness of mind, the like period of time after such disability shall be removed. However, the saving in favor of persons under disability of unsoundness of mind shall never extend longer than thirty-one years.
In reviewing the above statute, it should be noted that by its own terms, the ten-year statute of limitations is restricted, "in case of the existence of a trust not cognizable by the courts of common law ..." We have construed this provision to make the ten-year limitation applicable to both express and implied trusts. Hook v. Bank of Leland, 134 Miss. 185, 98 So. 594 (1924). However, the application of § 15-1-39 is limited, in that the cause of action and remedy of the case must be purely and exclusively equitable, Id., or the general six-year statute of limitations will be applied. In the present case, the chancellor below determined in separate orders that both Wholey and Rodgers' actions were one based upon fraud, which is cognizable by the courts of common law. Once this determination was made, the lower court granted Cal-Maine's summary judgment motions on the basis that the actions were barred by the six-year statute of limitations. Thus, this Court's key inquiry on appeal should be whether or not appellants' actions are cognizable at law, i.e. fraud as found by the chancellor, or whether they are a pure equitable matter, mandating the application of § 15-1-39. Hook, supra.
In their complaints, appellants alleged that Cal-Maine had fraudulently converted the capital of the limited partnership to its own use, made concealed profits through self-dealing, breached its fiduciary duty to the limited partners and failed to exercise good faith and integrity with respect to partnership affairs. Appellants requested an accounting of all records, books, and affairs of National Farming Program/1973, and further that Cal-Maine be ordered to pay overall unlawful charges and profits. *140 Still, the critical question is whether the actions were in the nature of fraud, or a trust not cognizable by the common law courts. In this regard, Miss. Code Ann. § 79-12-41 (1972) concerning partnership dealings provides in part that:
Partner accountable as a fiduciary.
(1) Every partner must account to the partnership for any benefit, and hold as trustee for it any profits derived by him without the consent of the other partners from any transaction connected with the formation, conduct, or liquidation of the partnership or from any use by him of its property. (Emphasis added)
This code section comports readily with appellants' argument that their causes of action were in nature of a constructive trust arising out of the relations of the limited partnership. It is further stated that:
Taking secret commission or profit.

A confidant or fiduciary may be held as a constructive trustee in respect of secret profits or commissions obtained by the violation of a confidence or duty that he should be carrying out rather than violating, whether his conduct is affirmatively fraudulent, whether his principal or confider suffers loss from the violation of duty, and whether the confider or beneficiary affirms or disaffirms the breach of confidence. The rule is applicable in the case of parties to a community of interest creating fiduciary relationships among them, or about to enter into such a community of interest. The very fact that one party conceals his true interest from the other indicates a purpose to gain some advantage at the other's expense, or a belief that disclosure would influence the other in deciding whether and upon what terms to enter into the community of interest. (Emphasis added)
76 Am.Jur.2d Trusts, § 232 at p. 455 (1975). Again, appellants alleged below that Cal-Maine made secret profits from the limited partnership by breaching its fiduciary duty to the limited partners. As seen above, this is one of the situations in which a constructive trust may be properly applied.
In Stebbins v. Hayes, 379 So.2d 898 (Miss. 1980), this Court looked to the allegations in the complaint in determining that the theory of the case was in the nature of an implied trust or the right to a partnership accounting, so as to mandate the application of the ten-year statute of limitations in § 15-1-39. So to, the present complaints were based upon the breach of a fiduciary duty by Cal-Maine giving rise to the imposition of an implied trust, and of necessity a partnership accounting. The lower court erred when it applied the six-year statute of limitations and granted Cal-Maine summary judgments on this point.

III. DID THE LOWER COURT ERR WHEN IT DETERMINED THAT THE APPROPRIATE STATUTE OF LIMITATIONS BEGAN TO RUN BY FEBRUARY 28, 1979?
The lower court found that the statute of limitations in both actions began to run on February 28, 1979. The significance of this date, as found by the chancellor, was that appellants had been advised by correspondence from Cal-Maine that the assets of National Farming Program/1973 were gone and that there would be no return of contributed capital to the limited partners. Appellants argue that the limitations period should not have begun to run until April, 1980, when they were first given the opportunity to inspect the limited partnership books.
As previously discussed under Section II of this opinion, appellants' actions were for the imposition of an implied or constructive trust. This was appellants' argument at trial, as now on appeal. The right to enforce an implied or constructive trust accrues at the time of performance of the act from which the trust results. Stebbins v. Hayes, 379 So.2d 898 (Miss. 1980). The statute runs from the time when the act was done by which the party became chargeable as trustee by implication. Rimmer v. Austin, 191 Miss. 664, 4 So.2d 224 (1941); See also Sullivan v. Nobles, 211 Miss. 330, 51 So.2d 736 (1951); Prewett v. *141 Buckingham, 28 Miss. 92 (1854). Following this test, the act of overreaching by Cal-Maine, leading to unagreed to profits, if any, would have occurred prior to Cal-Maine's informing appellants that the capital of the limited partnership was expended. The assignment of error is without merit.

CONCLUSION
The lower court erred when it granted summary judgment in favor of Cal-Maine on the basis of: 1) res judicata, and 2) the application of the six-year statute of limitations. The decision of the lower court in both cases is reversed and remanded.
REVERSED AND REMANDED.
ROY NOBLE LEE, C.J., HAWKINS and DAN M. LEE, P.JJ., and ROBERTSON, SULLIVAN, ANDERSON and GRIFFIN, JJ., concur.
PRATHER, J., not participating.
