
599 N.E.2d 531 (1992)
234 Ill. App.3d 232
174 Ill.Dec. 747
Christopher PATSIS, Plaintiff-Appellant,
v.
ZION-BENTON TOWNSHIP HIGH SCHOOL, No. 126, et al., Defendants-Appellees.
No. 2-91-0908.
Appellate Court of Illinois, Second District.
September 3, 1992.
*532 Robert A. Clifford, Robert P. Sheridan, Keith A. Hebeisen, Robert A. Clifford & Associates, Chicago, for Christopher Patsis.
Wayne F. Plaza, Carolyn N. Offenbach, Rooks, Pitts and Poust, Chicago, for Zion-Benton Tp. and Kay Marie Niemi.
*533 Justice BOWMAN delivered the opinion of the court:
Plaintiff, Christopher Patsis, appeals the order of the Lake County circuit court which granted the motion of defendant, Zion-Benton Township High School District No. 126 (Zion-Benton), to dismiss the cause with prejudice. Plaintiff contends that defendant waived its statute of limitations defense when it filed a contribution action against him in another pending suit regarding a claim which arose from the same occurrence. Plaintiff also argues that the trial court abused its discretion by denying his motion to dismiss his complaint voluntarily when plaintiff sought to refile his action in the other pending suit.
This litigation involves an accident that occurred on April 6, 1989. Bobby Lane Taylor was a passenger in plaintiff's car and sustained injuries when plaintiff's car collided with defendant's school bus, which was operated by Kay Marie Niemi. Taylor filed a lawsuit against defendant and Niemi in the circuit court of Lake County, case No. 90-L-436 (hereinafter referred to as the Taylor proceeding), which is not included in the record before this court.
On October 9, 1990, plaintiff filed the action which is the subject of this appeal. He alleged that Zion-Benton and Niemi were negligent for failing, inter alia, to stop at a stop sign. Plaintiff sought damages for injuries that he himself suffered. On December 27, 1990, Zion-Benton filed a motion to vacate any defaults and a motion to dismiss the cause on the ground of the statute of limitations. The one-year period for filing suit against public entities specified in section 8-101 of the Local Governmental and Governmental Employees Tort Immunity Act (Tort Immunity Act) (Ill.Rev. Stat.1991, ch. 85, par. 8-101) had expired. In response, plaintiff filed a motion to dismiss voluntarily under section 2-1009 of the Code of Civil Procedure (Ill.Rev.Stat. 1991, ch. 110, par. 2-1009) for the reason that another action was pending concerning the same facts. Plaintiff attached an undated copy of Zion-Benton's third-party complaint in cause No. 90-L-436, in which it sought contribution against plaintiff for any liability it had for Taylor's injuries. Zion-Benton alleged in its third-party complaint that plaintiff was negligent in failing, inter alia, to decrease his speed.
The trial court did not permit plaintiff to dismiss his complaint but instead granted Zion-Benton's motion to dismiss it involuntarily with prejudice. After plaintiff obtained service of process on Niemi, she filed a motion to dismiss on the ground of the statute of limitations. The trial court granted her motion, and plaintiff filed his timely notice of appeal pursuant to Supreme Court Rule 301 (134 Ill.2d R. 301) concerning both dismissal orders.
Plaintiff contends that the trial court abused its discretion by denying his motion for a voluntary dismissal. Plaintiff also contends that Zion-Benton waived the statute of limitations defense when Zion-Benton filed its third-party complaint against him in the Taylor proceeding. Plaintiff also attempts to argue that the trial court's judgment was unjust based on events outside the record. Plaintiff asserts that Zion-Benton is attempting to dismiss his third-party counterclaim in cause No. 90-L-436, the Taylor proceeding, on the ground of res judicata based on the judgment in the cause before this court. This fact is not in the record and cannot be considered by this court. If plaintiff suffers prejudice from an improper application of the doctrine of res judicata in cause No. 90-L-436, he must move for a finding that there is no just cause to delay enforcement or appeal of the dismissal of his third-party counterclaim; he may then file an appeal under Rule 304(a) (134 Ill.2d R. 304(a)) rather than wait until the end of the litigation. We have no jurisdiction over the Taylor proceeding (Lee v. Pavkovic (1983), 119 Ill. App.3d 439, 444, 74 Ill.Dec. 900, 456 N.E.2d 621), and we have no record to support a review of the issues in that case (Foutch v. O'Bryant (1984), 99 Ill.2d 389, 391-92, 76 Ill.Dec. 823, 459 N.E.2d 958).
Plaintiff argues that Zion-Benton waived the application of the statute of limitations and cites section 13-207 of the Code of Civil Procedure (Ill.Rev.Stat.1991, ch. 110, par. 13-207), which provides that a *534 defendant may plead a setoff or a counterclaim barred by the statute of limitations to any action raised by the plaintiff. One purpose of section 13-207 is to protect parties who have shorter limitations periods than their opponents. (See Wood Acceptance Co. v. King (1974), 18 Ill.App.3d 149, 151, 309 N.E.2d 403.) Zion-Benton argues that section 13-207 does not apply because plaintiff filed as the first party in an original proceeding and not as a second party with a counterclaim.
Zion-Benton also argues that plaintiff waived the application of section 13-207 because he failed to raise it before the trial court. (See Cuerton v. American Hospital Supply Corp. (1985), 136 Ill. App.3d 231, 238-39, 90 Ill.Dec. 480, 482 N.E.2d 187.) Instead, plaintiff had moved for an enlargement of time to respond to Zion-Benton's motion to dismiss as an alternative to his motion to dismiss voluntarily. The doctrine of waiver acts as an admonition to the parties rather than a limitation on the court. (People v. Hoskins (1984), 101 Ill.2d 209, 219, 78 Ill.Dec. 107, 461 N.E.2d 941.) Because the record is sufficient to support a discussion of the statute, and we cannot avoid discussing the equitable issues without reference to the statute, we may discuss the statute. See Bell v. Louisville & Nashville R.R. Co. (1985), 106 Ill.2d 135, 142, 88 Ill.Dec. 69, 478 N.E.2d 384.
We agree that plaintiff could not take the benefit of the statute in the instant action. Section 13-207 is a remedy that was not available to him in the instant action but is available in an action where he is defending. (See Helle v. Brush (1973), 53 Ill.2d 405, 409, 292 N.E.2d 372 (fundamental fairness requires allowance of counterclaim against a public entity in spite of the shorter period of section 8-101).) In addition, plaintiff did not file his complaint to seek contribution, as he was not being sued at the time, and he could not apply section 13-204 of the Code of Civil Procedure (Ill.Rev.Stat.1991, ch. 110, par. 13-204), which provides for a two-year statute of limitations for contribution claims. His right to contribution against Zion-Benton, if any, did not accrue until Zion-Benton filed its third-party claim against him in the Taylor proceeding. (Highland v. Bracken (1990), 202 Ill.App.3d 625, 633, 148 Ill.Dec. 104, 560 N.E.2d 406.) Zion-Benton was required to file its claim for contribution in the Taylor proceeding because that cause was already pending. (See Laue v. Leifheit (1984), 105 Ill.2d 191, 195, 85 Ill.Dec. 340, 473 N.E.2d 939.) In that action, plaintiff has a right to file a third-party counterclaim and to raise section 13-207, which was not available in the instant action.
We have found no direct authority to support plaintiff's argument that his claim may survive in an original proceeding when the adverse party has filed a claim against him in another proceeding. With liberal joinder provisions and mandatory counterclaims, and with the reluctance of attorneys to file complaints which may fall prey to the statute of limitations, the issue seldom arises. Plaintiff cites Ogg v. City of Springfield (1984), 121 Ill.App.3d 25, 76 Ill.Dec. 531, 458 N.E.2d 1331, where one defendant, Coleman, contended a counterclaim for contribution filed by another defendant, Henrici, was barred by the statute of limitations. This defense of Coleman had been waived when he filed a claim for contribution against Henrici; it remained waived even after Coleman's claim was later dismissed. (121 Ill.App.3d at 33-34, 76 Ill.Dec. 531, 458 N.E.2d 1331.) However, in Ogg, the counterclaim was raised within the pending suit and not as a new cause of action.
In essence, plaintiff does not rely upon section 13-207 itself but upon general rules of equity and estoppel in arguing that his claim should survive when his opponent has filed a claim against him. Plaintiff contends that once Zion-Benton filed its third-party claim for contribution, it waived the application of the statute of limitations for claims against itself; that the waiver was irrevocable (see Ogg, 121 Ill.App.3d at 33, 76 Ill.Dec. 531, 458 N.E.2d 1331); and that plaintiff's claim is no longer barred. Plaintiff cites cases where the statute of limitations has been deemed waived based on the opponent's actions outside the subject *535 of the litigation. (E.g., Tri-City Jewish Center v. Blass Riddick Chilcote (1987), 159 Ill.App.3d 436, 440, 111 Ill.Dec. 247, 512 N.E.2d 363.) Waiver is the relinquishment of a right by conduct inconsistent with an intent to enforce the right. (Rummel v. Yazoo Manufacturing Co. (1991), 222 Ill.App.3d 526, 531, 164 Ill.Dec. 465, 583 N.E.2d 19.) A public entity may waive some benefits of the Tort Immunity Act's limitations of actions when it initiates an action against a party with an otherwise barred claim. (Helle, 53 Ill.2d at 410, 292 N.E.2d 372.) While ultimately we do not need to decide whether Zion-Benton waived the statute of limitations because we resolve plaintiff's other issue on appeal, we discussed it because it explains the equities involved in the other issue.
Plaintiff also contends that the trial court abused its discretion in not granting his statutory right to dismiss his complaint voluntarily. Section 2-1009 of the Code of Civil Procedure gives a plaintiff the unfettered right to dismiss his action without prejudice at any time prior to trial. (Ill. Rev.Stat.1991, ch. 110, par. 2-1009.) To avoid potential abuses arising from the use of this statute, the supreme court decided that a trial court may consider a previously filed dispositive motion before allowing the plaintiff's motion to dismiss. (Gibellina v. Handley (1989), 127 Ill.2d 122, 138, 129 Ill.Dec. 93, 535 N.E.2d 858.) The trial court is endowed with the discretion to consider the prior motion and must strike a balance between the legislative grant to plaintiffs of an unfettered right to dismiss voluntarily and the abuse which that unfettered right has engendered from some plaintiffs. (Mizell v. Passo (1992), 147 Ill.2d 420, 425, 168 Ill.Dec. 812, 590 N.E.2d 449.) The court in Gibellina did not establish a set of guidelines but left the decision to the trial court's discretion. (Mizell, 147 Ill.2d at 425, 168 Ill.Dec. 812, 590 N.E.2d 449.) In Mizell, the trial court did not abuse its discretion when it allowed the plaintiff to withdraw his complaint when he could not supply the medical affidavit required in his cause in a timely fashion. 147 Ill.2d at 426-27, 168 Ill.Dec. 812, 590 N.E.2d 449; cf. McDaniel v. St. Elizabeth's Hospital (1991), 213 Ill.App.3d 103, 107, 157 Ill.Dec. 184, 571 N.E.2d 1203 (motion to dismiss is not an abuse where proceedings were not advanced).
It is clear that plaintiff did not file his motion to dismiss for any abusive purpose. He noted that another action was pending which was a better, if not required, forum for the consideration of his claim and that the consideration of his claim in that action would serve judicial economy. In addition, the other proceeding would provide a decision on the merits of his action against Zion-Benton since Zion-Benton had filed a claim against him arising out of the same occurrence. In Gibellina, the supreme court permitted the consideration of potentially dispositive motions when to do so would prevent plaintiffs from using the nonsuit statute to avoid an adverse ruling on the merits of the cause rather than using it to correct a procedural or technical defect. (Gibellina, 127 Ill.2d at 137, 129 Ill.Dec. 93, 535 N.E.2d 858.) In the instant cause, if Zion-Benton has a valid statute of limitations defense, Zion-Benton can raise it just as well in the other action; thus, plaintiff was not abusively avoiding an adverse ruling by seeking a nonsuit. Rather, he was seeking to correct a procedural or technical defect, which underlies the very purpose of the common-law procedure of nonsuit codified in section 2-1009. The motion would not have increased the burden on the crowded docket. (See Gibellina, 127 Ill.2d at 137, 129 Ill. Dec. 93, 535 N.E.2d 858.) This was not a case where the parties conducted extensive discovery, incurred substantial costs or suffered undue prejudice from the proceedings prior to the motion for a nonsuit. (McDaniel, 213 Ill.App.3d at 107, 157 Ill.Dec. 184, 571 N.E.2d 1203.) Therefore, we hold that the trial court abused its discretion in considering Zion-Benton's motion to dismiss prior to plaintiff's right to nonsuit his cause.
In contrast, not allowing the motion for a voluntary dismissal would result in an abuse of process. The statute of limitations is an affirmative defense to a *536 proceeding and applies only when raised by a party; the party asserting it has the burden to show it applies. (C.S. Johnson Co. v. Champaign National Bank (1984), 126 Ill.App.3d 508, 511, 81 Ill.Dec. 663, 467 N.E.2d 363. But see People ex rel. Foreman v. Village of Round Lake Park (1988), 171 Ill.App.3d 443, 450, 121 Ill.Dec. 561, 525 N.E.2d 868 (failure to plead an affirmative defense does not constitute waiver if the defense is raised before trial).) Thus, a plaintiff may bring an action which may be later dismissed under the statute of limitations. It would then be inequitable to allow the former defendant to initiate a new suit and be free from a counterclaim and setoff arising from the same occurrence on the ground that the counterclaim was previously barred. This result would be egregiousespecially when the defendant's action was pending at the time of the dismissal of the plaintiff's action. Thus, plaintiff's nonsuit in the cause before the court was an attempt to avoid an abuse of process rather than an abuse of process itself.
Here, plaintiff could have filed a motion to consolidate the causes under section 2-1006 of the Code of Civil Procedure (Ill.Rev.Stat.1991, ch. 110, par. 2-1006) or sought to join the Taylor proceeding under section 2-614 (Ill.Rev.Stat.1991, ch. 110, par. 2-614). The Code provides that seeking the wrong remedy is not fatal (Ill.Rev. Stat.1991, ch. 110, par. 2-617) and that the Code is to be liberally construed (Ill.Rev. Stat.1991, ch. 110, par. 1-106). The purpose of the Code is to provide substantial justice and a resolution on the merits rather than to impose procedural hurdles to litigation. (Adams v. Klink (1991), 210 Ill.App.3d 630, 637, 155 Ill.Dec. 361, 569 N.E.2d 542; Wolf v. Meister-Neiberg, Inc. (1990), 194 Ill.App.3d 727, 730-31, 141 Ill. Dec. 360, 551 N.E.2d 353.) Plaintiff's attempt to nonsuit his cause and refile it in the more appropriate proceeding would have accomplished the same goals as a consolidation or joinder. Thus, the trial court should have allowed the motion to dismiss voluntarily.
Finally, plaintiff acknowledges that his arguments concerning Zion-Benton's waiver of the statute of limitations do not apply to Niemi as she did not initiate a proceeding against him; thus, plaintiff could not file a counterclaim against her other than one for contribution. When he moved to dismiss voluntarily, she had not filed a dispositive motion against him, and she had not appeared. However, when plaintiff moved to dismiss his cause voluntarily, the court would have dismissed the whole cause. Since the cause would have been dismissed prior to her appearance and her motion to dismiss involuntarily, the order of July 10, 1991, granting her motion must be vacated.
For the above reasons, the order of the circuit court of Lake County is reversed, and the cause is remanded for entry of the proper orders consistent with this disposition.
Reversed and remanded.
INGLIS, P.J., concurs.
Justice NICKELS, specially concurring:
After expressly rejecting consideration of any matters outside the record, but nevertheless discussing the equities of this case in detail, the majority correctly concludes that the circuit court abused its discretion in failing to rule on plaintiff's motion to dismiss voluntarily prior to granting defendant's motion to dismiss with prejudice. However, in succumbing to the lure of equitable considerations, the majority overlooks the narrow parameters within which a circuit court may exercise such discretion.
Although a circuit court has the discretion to decide a previously filed dispositive motion prior to a motion to dismiss voluntarily, the exercise of such discretion is limited to only those instances necessary to prevent abuse of the voluntary dismissal process. (Gibellina, 127 Ill.2d at 137-38, 129 Ill.Dec. 93, 535 N.E.2d 858.) Therefore, if the initial determination finding such abuse of the voluntary dismissal process is against the manifest weight of the evidence, the circuit court has exceeded the limits of its discretion. See Mizell, 147 *537 Ill.2d at 425-26, 168 Ill.Dec. 812, 590 N.E.2d 449.
In this instance, plaintiff sought voluntarily to dismiss his claim and, although not required to do so, expressly explained in his motion that the reason he was seeking voluntary dismissal was that another action was pending concerning the same facts. Thus, there is nothing in the record to support the conclusion that this was an instance of abuse of the voluntary dismissal process, and, in fact, the record belies such conclusion. Any finding that this was an abuse of the voluntary dismissal process is, therefore, necessarily against the manifest weight of the evidence, and it is unnecessary to delve into the equitable considerations presented to find that the circuit court abused its discretion in failing to rule on plaintiff's motion for voluntary dismissal prior to defendant's dispositive motion.
