delivered the opinion of the court:
Appellant was a contractor on a construction project for appellee, the owner of the property. After the work was completed a subcontractor filed suit to foreclose its mechanics’ lien. Although appellant was joined as a defendant in the action, it did not file a counterclaim to foreclose its own lien until well after two years from the date of completion of the project. Accordingly appellee successfully moved to have appellant’s lien expunged. The trial court also denied appellant’s motion to amend its complaint to add a counterclaim seeking to foreclose the lien. We affirm, holding that:
(1) by statute (Ill. Rev. Stat. 1977, ch. 82, par. 9), the contractor to preserve its lien was required to file a suit or counterclaim within two years after completion of the contract. Since the contractor failed to do either within the two-year period, the lien was properly expunged; and
(2) liberal as section 46(2) of the Civil Practice Act (Ill. Rev. Stat. 1981, ch. 110, par. 46(2)), now section 2 — 616(b) of the Code of Civil Procedure (Ill. Rev. Stat. 1981, ch. 110, par. 2 — 616(b)), is, the appellant cannot, after the time for protecting its lien has passed, amend its answer to add a counterclaim to foreclose the lien.
On July 28, 1975, Steven Brown as owner, executed a construction contract with Bonnie Dee Builders, as contractor. According to the contract, the contractor was to construct an extensive addition to the owner’s existing store. Disagreements arose during the course of construction. The owner contended the building was not completed on time, did not comply with city codes and was not constructed in a workmanlike manner. The contractor and various subcontractors filed mechanics’ liens. It is not clear from the record exactly when the construction was completed, probably around June 1976.
On September 10, 1976, one subcontractor, Well Done Heating & Sheet Metal Co. (Well Done), filed suit to foreclose its mechanics’ lien. It joined the owner, contractor, and several subcontractors who had or claimed a lien on the property. Well Done sought recovery against both the owner and the contractor. Contractor filed an answer which admitted all of the allegations of the complaint to foreclose including the allegation that contractor had or claimed a lien on the property. It asked that an accounting be taken by the court as to the amount due subcontractor; that subcontractor be decreed to be entitled to a mechanics’ lien but that owner and not contractor be held liable for the amount due Well Done and that contractor be decreed free of said indebtedness. Well Done had asked that if the amount was not paid, the property be foreclosed and defendants (including contractor) be barred of all right in the premises. Contractor did not respond to the prayer. It also did not in any manner ask that its own lien be protected or foreclosed. Other subcontractors did file counterclaims for foreclosure of their mechanics’ liens.
In 1979 the contractor filed a counterclaim in contract against the owner for the unpaid portion of the contract price. There was no request for foreclosure. In 1980 Well Done’s claim was settled and its complaint dismissed with prejudice. Although such dismissal is prohibited by section 9 of the Mechanics’ Lien Act (Ill. Rev. Stat. 1979, ch. 82, par. 9), except with the consent of the other lien claimants, there is no evidence in the record that contractor ever objected to this dismissal.
In 1982, about six years after the building was completed, owner moved to expunge the lien filed by contractor since no suit or counterclaim had been filed by contractor within the two years required by statute. The trial court held that the answer satisfied the requirements of the act but concluded that it became moot when the complaint was dismissed. It therefore granted the motion to expunge. The trial court also denied contractor’s motion to amend its answer to add a cross-complaint to foreclose since that amendment set forth a new cause of action and was barred by the time limitations of section 9 of the Mechanics’ Lien Act.
I
The contractor contends that section 9 of the Mechanics’ Lien Act unambiguously provides that once a mechanics’ lien claim has been filed by one lien claimant, an answer thereto by another lien claimant, filed within two years after the completion of the work, is sufficient to permit enforcement of the second claimant’s lien; that the court may not require any further pleadings and that this has been the law in Illinois for over a century.
First of all it would appear that contractor’s answer here was insufficient to set up a lien claim even under the old law. Those cases seem to hold that an answer setting forth fully the facts upon which a claim for a lien was founded, and asserting the lien against the fee title, thus asserting a claim for affirmative relief, is sufficient to set forth a claim for foreclosure. (E. W. Blatchford & Co. v. Blanchard (1895), 160 Ill. 115, 43 N.E. 794; Thielman v. Carr (1874), 75 Ill. 385; Gilbert v. Croshaw (1913), 178 Ill. App. 10; Shields v. Sorg (1906), 129 Ill. App. 266, aff’d (1908), 233 Ill. 79, 84 N.E. 181.) The answer in this case did not set forth fully the facts upon which a lien claim was founded or in any other way set out a claim for affirmative relief. To the contrary, contractor, while praying that only the owner be held liable, did not answer subcontractor’s prayer that if the property be foreclosed, defendants, including contractor, be barred of all rights in the property.
We need not decide this question, however, since the statute was amended before contractor’s answer was filed and no longer permits an answer to serve as a cross-bill or counterclaim as the statute provided. The statute prior to October 1,1976, read:
“If payment shall not be made to the contractor having a lien by virtue of this act of any amount due when the same becomes due, then such contractor may bring suit to enforce his lien by complaint or petition in any court of competent jurisdiction in the county where the improvement is located, and in the event that the contract relates to two or more buildings or two or more lots or tracts of land, then all of said buildings and lots or tracts of land may be included in one complaint or petition. Any two or more persons having liens on the same property may join in bringing such suit, setting forth their respective rights in their complaint or petition; all lien claimants not made parties thereto may upon application become defendants and enforce their liens by answer to the complaint or petition in the nature of an intervening petition, and the same shall be taken as a counterclaim against all the parties to such suit; and the said complaint or petition shall not thereafter be dismissed as to any such lien claimant, or as to the owner or owners of the premises without the consent of such lien claimant. The plaintiff or petitioner, and all defendants to such complaint or petition may contest each other’s right without any formal issue of record made up between them other than that shown upon the original complaint or petition, as well with respect to the amount due as to the right to the benefit of the lien claimed: Provided, that if by such contest by co-defendants any lien claimants be taken by surprise, the court may, in its discretion, as to such claim, grant a continuance. The court may render judgment against any party summoned and failing to appear, as in the other cases of default. Such suit shall be commenced or answer filed within two years after the completion of the contract, or completion of the extra or additional work, or furnishing of extra or additional material thereunder.” (Emphasis added.) (Ill. Rev. Stat. 1975, ch. 82, par. 9.)
(Earlier statutes were similar in wording.) But effective October 1, 1976, the statute now reads in relevant part:
“Any two or more persons having liens on the same property may join in bringing such suit, setting forth their respective rights in their complaint; all lien claimants not made parties thereto may upon filing a petition to intervene become defendants and enforce their liens by counterclaim against all the parties to the suit; and the complaint shall not thereafter be dismissed as to any lien claimant, or as to the owner or owners of the premises without the consent of such lien claimant. The plaintiff and all defendants to such complaint may contest each other’s right without any formal issue of record made up between them other than that shown upon the original complaint, as well with respect to the amount due as to the right to the benefit of the lien claimed: Provided, that if by such contest by co-defendants any lien claimants be taken by surprise, the court may, in its discretion, as to such claim, grant a continuance. The court may render judgment against any party summoned and failing to appear, as in other cases of default. Such suit shall be commenced or counterclaim filed within two years after the completion of the contract, or completion of the extra or additional work, or furnishing of extra or additional material thereunder.” (Emphasis added.) (Ill. Rev. Stat. 1977, ch. 82, par. 9.)
All references to “answer” in the previous statutes have been removed and replaced by the word “counterclaim” and the provision in the old statutes that the answer or intervening petition should be taken as a counterclaim has been deleted. Thus it is clear that under the statute, as amended, an answer, at least one failing in effect to set forth a counterclaim and ending with an appropriate prayer for relief (see Ill. Rev. Stat. 1977, ch. 110, par. 34, now Ill. Rev. Stat. 1981, ch. 110, par. 2—604); Thielman v. Carr (1874), 75 Ill. 385), is insnfficip.nt to preserve the lien claim. The lienor must either file a suit or a counterclaim within the two-year period or its claim falls and it has no right to a lien (Rochelle Building Co. v. Oak Park Trust & Savings Bank (1970), 121 Ill. App. 2d 274, 257 N.E.2d 542), since the time fixed for commencing an action under the Mechanics’ Lien Act is a condition of liability and not of the remedy alone. North Side Sash & Door Co. v. Hecht (1920), 295 Ill. 515, 129 N.E. 273; Muehlfelt v. Vlcek (1969), 112 Ill. App. 2d 190, 250 N.E.2d 14; Anderson v. Gousset (1965), 60 Ill. App. 2d 309, 208 N.E.2d 37.
The contractor contends that the statutory language does not apply to it because it was made an original defendant by the complaint and the pertinent clauses only apply to lien claimants not made parties to the suit. That same contention, however, was made and rejected in Rochelle Building Co. v. Oak Park Trust & Savings Bank (1970), 121 Ill. App. 2d 274, 257 N.E.2d 542. Rochelle held that even though the party in question was made a defendant by the original complaint, as was the contractor in the present case, he could not rely on the date the suit was brought and since he only filed his appearance and failed to file an answer (as already noted the statute in 1970 referred to answers) or counterclaim within the two-year period, his lien was lost. Here, the statute expressly requires that either the suit or the counterclaim be filed within two years if the lien is to be protected. It no longer permits an answer to suffice for this purpose. The contractor did not file a counterclaim within two years. While a suit was filed within two years, it was not filed by the contractor. As held in Rochelle the contractor, although named as a defendant in the suit, was still required to file his own suit or counterclaim and could not rely on the fact a subcontractor filed his own lien action. The filing of the answer which sought no affirmative relief was not equivalent to filing its own suit under the statute. Rochelle; Galloy v. Sparrow (1911), 166 Ill. App. 197.
II
Contractor contends that in any event it should have been allowed to amend its answer to add the counterclaim since section 46(1) of the Civil Practice Act (Ill. Rev. Stat. 1981, ch. 110, par. 46(1)), now section 2 — 616(a) of the Code of Civil Procedure (Ill. Rev. Stat. 1981, ch. 110, par. 2 — 616(a)), allows a pleading to be amended any time up to judgment. Section 46(1), however, is not applicable since while it permits amendments up to judgment, it does not provide for amendments after the statute of limitations has ran. Sections 46(2) and 46(4) do under certain limited circumstances but they are not applicable here. Ill. Rev. Stat. 1981, ch. 110, par. 46(2), (4).
While Illinois allows a party to amend its pleading, even sometimes to the extent of altering the nature of the claim previously made, it is still the law that generally an amendment asserting a new cause of action is not permitted once the statute of limitations has expired (Millsaps v. Bankers Life Co. (1976), 35 Ill. App. 3d 735, 342 N.E.2d 329, appeal denied (1976), 63 Ill. 2d 552; Beam v. Erven (1971), 133 Ill. App. 2d 193, 272 N.E.2d 685), particularly where, as here, there had been no attempt of any kind to set forth the claim prior to the running of the statute.
This case is remarkably similar to the recent case of Shriners Hospitals for Crippled Children v. First National Bank (1981), 101 Ill. App. 3d 626, 428 N.E.2d 751, appeal denied (1982), 88 Ill. 2d 555, which we find persuasive. Shriners involved a will contest. A party seeking to contest a will must do so within six months after the admission of the will to probate just as a contractor wishing to preserve his lien must file suit or counterclaim within two years from the date of completion. In Shriners a beneficiary under a previous will filed suit to contest the will naming among the defendants Masonic Home, a beneficiary under both the wills. Likewise in our case, Well Done, a subcontractor, filed suit against several defendants including the contractor and sought both to recover from the contractor and to bar contractor’s rights in the property. In Shriners, Masonic merely filed an answer demanding Shriners make strict proof of its allegations; it did not, at that time, seek to contest the will. In the present case, contractor merely denied its liability to the subcontractor; it did not, at that time, seek to foreclose its own lien. In Shriners, after the six-month period expired, Shriners over Masonic’s objection moved to have its petition dismissed with prejudice which motion was later granted. In the present case, Well Done did dismiss its complaint with prejudice; there was no objection by the contractor. In Shriners, when Shriners sought to dismiss its complaint, Masonic sought leave to amend its answer by adding a counterclaim contesting the present will. In the present case, the contractor over IV2 years after the dismissal of the complaint sought to amend its answer to add a counterclaim to foreclose its lien. The court in Shriners denied the motion to amend the answer, stating at 101 Ill. App. 3d 626, 629-30, 428 N.E.2d 754:
“A broad reading of Nupnau and Watt might suggest that section 46 of the Civil Practice Act is controlling once a will contest has been timely filed by any party. However, it is important to note that in neither of those cases, nor in any other case cited by those courts, was a party seeking to change its position from that of a party supporting the will to that of a party attacking the will. Such a realignment would have the effect of allowing one party to take advantage of another party’s timely actions, even though each party originally had its own cause of action to contest the will and one party chose not to do so within the required time.
In essence, this is what has happened. Masonic Home had a cause of action for the contest of the decedent’s purported will for the 6-month statutory period. It chose not to assert that cause of action. In like manner, Shriners also had a cause of action for contest of the decedent’s purported will. It chose to assert its cause of action by commencing this suit. Masonic Home entered the case by filing an answer which was silent as to its own cause of action. It chose alignment in the suit as a defendant, or perhaps as a neutral, rather than as a contestant. When Shriners then withdrew its suit, Masonic Home moved to be permitted to assert the cause of action possessed by Shriners. We hold that even a liberal interpretation of section 46 of the Civil Practice Act does not permit such realignment in this case.”
In addition, it is well settled in Illinois that a complaint to foreclose a mechanics’ lien cannot, after the statutory period, be amended to add a new defendant. (Muehlfelt v. Vlcek (1969), 112 Ill. App. 2d 190, 250 N.E.2d 14; Anderson v. Gousset (1965), 60 Ill. App. 2d 309, 208 N.E.2d 37.) Contractor contends this rule is inapplicable since the owner was already a party to the suit. But the owner was not a party to any claim filed by contractor because contractor had filed no claim. Furthermore, it was established in Dignan v. Midas-International Corp. (1978), 65 Ill. App. 3d 188, 382 N.E.2d 559, that a cross-claim against a co-defendant cannot be brought once the statute of limitations has run.
For the foregoing reasons, the judgment of the trial court expunging the lien and denying the motion to amend the complaint is affirmed.
Affirmed.
LINN, J., concurs.