
634 N.E.2d 1312 (1994)
262 Ill. App.3d 614
199 Ill.Dec. 958
FARM CREDIT BANK OF ST. LOUIS, a Federally chartered corporation, Plaintiff,
v.
James A. BIETHMAN, Consolidated Insurance Agency, Inc., United Fire and Casualty Company, and Magna Bank of Centralia, Defendant (United Fire and Casualty Company, Counterplaintiff-Appellee;
v.
James A. Biethman and Magna Bank of Southern Illinois, Counterdefendants-Appellants; Evansville Cement Finishers, Inc., Counterdefendant).
No. 5-92-0677.
Appellate Court of Illinois, Fifth District.
June 10, 1994.
*1313 Lashly & Baer, Randall F. Scherck, Sandra S. Watts, James C. Hetlage, St. Louis, MO, for James A. Biethman.
Steven M. Wallace, Carr, Korein, Tillery, Kunin, Montroy & Glass, East St. Louis, for Magna Bank of Southern Illinois.
David M. Duree, O'Fallon, of counsel; Bernard A. Reinert, John W. Rourke, Reinert, Duree & Crane, P.C., St. Louis, MO, for appellee.
*1314 Presiding Justice WILLIAM A. LEWIS delivered the opinion of the court:
The counterdefendants, James A. Biethman (Biethman) and Magna Bank of Southern Illinois (formerly known as Magna Bank of Centralia) (Magna Bank), appeal from a judgment of foreclosure entered on September 15, 1992, in favor of counterplaintiff, United Fire and Casualty Company (United Fire) in the principal amount of $700,000. On appeal, Biethman and Magna Bank raise the following issues: (1) whether the trial court erred in admitting into evidence a written agreement (agreement), dated September 13, 1990, between Biethman and United Fire, in addition to a promissory note and deed of trust executed by Biethman, since United Fire did not attach a copy of the agreement to its complaint; and (2) whether the trial court erred in denying Biethman's motion for judgment at the close of United Fire's case because (a) the evidence established that Biethman had paid the mortgage, and (b) no security interest existed above the face amount of the note. We affirm the judgment of the trial court for reasons we will more fully set forth.
On October 15, 1991, the original plaintiff, Farm Credit Bank of St. Louis (Farm Credit Bank), filed a complaint for foreclosure against Biethman, United Fire, and Magna Bank. On December 2, 1991, United Fire filed its answer to Farm Credit Bank's complaint and also filed a counterclaim for foreclosure of its promissory note and deed of trust against Farm Credit Bank, Biethman, Consolidated Insurance Agency, Inc. (Consolidated), and Magna Bank. United Fire attached copies of the promissory note and deed of trust signed by Biethman but neither referred to nor attached a copy of the agreement to the countercomplaint. Biethman filed his answer to the countercomplaint, requesting that the court "set aside" the trust deed and promissory note, in relevant part, because he did not owe and never had owed United Fire $700,000.
On January 21, 1992, the trial court entered a judgment of foreclosure in favor of Farm Credit Bank and against Biethman in the amount of $432,191.08 on their mortgage recorded June 1, 1989. Biethman then exercised his right of redemption, and the judgment of foreclosure was vacated as to Farm Credit Bank only.
On April 20, 1992, Biethman filed a motion to stay the proceedings or, in the alternative, for a continuance of the trial on United Fire's countercomplaint, alleging that United Fire had filed a case in Federal district court against Biethman and the company of which he was president, Evansville Cement Finishers, Inc. (ECF). Biethman attached a copy of the Federal court case and the agreement to his motion. The motion further alleged that the note and trust deed "which are the basis of United's cross-claim herein and the Agreement which is the basis of the Federal Court lawsuit are all dated September 13, 1990, and all arise out of the same transaction whereby United purportedly advanced funds to or on behalf of [Biethman] and [ECF]."
United Fire filed its response in opposition to Biethman's motion for stay or continuance, alleging that the circuit court action was not dependent upon the outcome of the Federal court case but depended only upon the validity of the promissory note and deed of trust. The trial judge denied the motion to stay but continued the case and granted leave to file amended affirmative defenses, to conduct discovery, and to file other motions.
On May 4, 1992, Biethman filed a "First Amended Answer to' Counterclaim," requesting again that the promissory note and deed of trust be set aside, inter alia, because the note and deed were given to United Fire without consideration.
On May 21, 1992, Biethman filed a memorandum by which he sought a ruling from the trial court to exclude "any evidence, whether by testimony, documents or otherwise regarding any amounts which were advanced by United Fire" to ECF or Biethman "in excess of $700,000." Also on May 21, 1992, the trial court conducted a hearing, in which Farm Credit Bank was allowed to prove up its defense to the counterclaim. Farm Credit Bank established that it had the first lien on the real estate in the amount of $341,465.77 plus attorney fees. Consolidated attempted to prove up its position but did not *1315 have sufficient evidence, and the issues with respect to Consolidated were reserved. Magna Bank established that it had a mortgage on the subject real estate, recorded on December 3, 1990, with a principal outstanding balance of $898,202.83.
After the other lienholders presented their evidence, Biethman's attorney argued that United Fire should not be allowed to introduce evidence of any money paid on behalf of Biethman or ECF above $700,000 because the promissory note was a "straight demand note," the mortgage was tied into the note, and neither contained any future advance clauses. The attorney for United Fire responded that the note and trust deed were "prepared as part of a larger transaction" and that the parties agreed that advances would be made pursuant to the note and deed of trust; however, he did not intend to prove that Biethman owed United Fire any more than the principal amount of the note, $700,000. In response to a question from the trial judge, Biethman's attorney stated that the defenses he intended to pursue were lack of consideration and payment of the note. The trial judge then asked how he could preclude United Fire from going into the entire transaction given Biethman's affirmative defenses. Biethman's attorney agreed that the lack of consideration defense opened the door for the court to consider the entire transaction.
On June 1, 1992, Biethman filed his second amended answer, alleging lack of consideration as an affirmative defense, as well as the affirmative defenses that neither the trust deed nor the promissory note contained a future-advance clause, and that the trust deed was void and invalid. On June 11,1992, the trial court entered an order denying Biethman's motion to exclude evidence regarding moneys advanced by United Fire in excess of $700,000 and finding that the lack of a future-advance clause in the trust deed was not fatal to the foreclosure.
On August 20,1992, the court proceeded to trial on United Fire's countercomplaint for foreclosure. For brevity's sake, we will summarize all of the evidence from this hearing together with the evidence presented to the court on September 2 and 3, 1992. United Fire's surety-claims representative, David Lange, testified that Biethman and Lange and several others met on September 11, 1990. Before the meeting, according to Lange, Biethman "had made it clear" he wished to meet with representatives of United Fire to obtain financial assistance in order to remain contractor of record on the numerous projects bonded by United Fire, because ECF faced default on several bonded jobs within a few days if it did not get funds from United Fire. Lange testified that the purposes of the bonds issued by United Fire to ECF were to guarantee the project owners that ECF would complete its contracts as it had promised the owners and to insure the subcontractors and suppliers of payment, but that ECF and Biethman were the principals, and that they were required first to exonerate and indemnify United Fire, but that if United Fire had to pay anything on behalf of ECF, ECF and Biethman were required to reimburse United Fire.
On January 23,1985, as part of the process of issuing bonds for ECF, Biethman and ECF entered into an agreement of indemnity (indemnity contract), which provided that if ECF defaulted on any project bonded by United Fire, United Fire was assigned an interest in all claims and equipment of ECF and that United Fire was authorized to advance funds to ECF or Biethman as necessary under the bonds. Lange testified, however, that United Fire was not required to advance any funds to or on behalf of Biethman or ECF until after all of the other provisions of the indemnity contract were exhausted: exoneration, indemnification, and assignment.
Lange testified that United Fire required Biethman to sign several documents before it would consent to help ECF with its financial difficulties. The documents Biethman executed included the $700,000 promissory note, the deed of trust, which covered real estate owned personally by Biethman, and the agreement. The deed of trust, which referred to the $700,000 promissory note, was recorded, but the note and the agreement were not recorded. All of the documents executed in connection with this transaction were admitted into evidence without any objection *1316 by Biethman, except for the agreement, which the trial court admitted over objection.
The agreement summarized the exact nature of the obligations of each party. In substance, Biethman acknowledged, through the agreement, that ECF had failed to comply with the terms of the bonds issued by United Fire, in that ECF had not paid certain sub-contractors and suppliers as required, that ECF lacked sufficient funds to continue work on its bonded jobs, and that ECF needed approximately $700,000 cash immediately. The agreement also provided that the exact amount United Fire would be obligated to pay on behalf of ECF in the future was undetermined.
The intent of the agreement was "to affirm" the obligations of each party under the bonds and the indemnity contract, "to protect" United Fire to the fullest extent possible on all of its bonded obligations, and to forestall the impending defaults which would have triggered the assignment of all of ECF's and Biethman's assets to United Fire. The parties agreed to open a joint banking account (the special account), which was initially funded by United Fire and which was the sole property of United Fire. Out of the special account, United Fire would pay for all bond claims as they arose and as United Fire deemed necessary. ECF and Biethman agreed to direct all funds from all of their bonded jobs to the special account. Checks could be written on the special account with the signature of one person from ECF and one from United Fire or with signatures of two persons from United Fire.
The agreement provided that Biethman was to execute a six-month promissory note to United Fire for $700,000 at nine per cent interest, to be secured by the deed of trust to Biethman's 250-acre tract of land adjoining Scott Air Force base. Lange testified that under the bonds and the indemnity contract, United Fire could not automatically attach Biethman's personal real estate as they could the personal property and equipment belonging to the corporation. The note and deed of trust were to be held by United Fire until ECF and Biethman fully indemnified or reimbursed United Fire for all of its losses and expenditures on behalf of ECF and Biethman. The note and deed of trust were listed as part of the overall obligation of ECF and Biethman to United Fire as a result of the bonds and the indemnity contract. Finally, the agreement provided that United Fire would release the note and deed of trust only after it was reimbursed for all expenditures and all liability under the bonds.
Lange testified that throughout the time the parties operated under the agreement, amounts needed to satisfy ECF's bonded obligations exceeded the amounts ECF earned on those jobs. Lange identified an exhibit that was a summary of financial involvement of United Fire with Biethman from September 19, 1990, through July 8, 1992. The summary listed the money paid out by United Fire on behalf of ECF, the sums paid to it to reduce the total balance owed by ECF and Biethman, and a running account of the total balance due from ECF and Biethman. The balance due under the promissory note from ECF and Biethman on March 13, 1991, six months after the note's execution, was over $950,000. Lange testified that the balance due was arrived at by subtracting income (the payments received directly from ECF and indirectly from the project owners) from outgo (the amounts paid out through the special account by United Fire on behalf of ECF). United Fire introduced this exhibit into evidence without objection. Lange testified that none of the money United Fire received from Biethman or ECF went toward payment of the promisory note, but rather, it went toward ECF's total obligation to United Fire on account of the bonds.
United Fire called one additional witness, Brian Bauer, who was the line officer on Biethman's accounts with Magna Bank until March 18, 1991. Bauer testified that Biethman had borrowed additional funds from Magna Bank during the spring and summer of 1990, but that Magna Bank refused to loan him any more money after September 1990 because his financial statement showed a loss and Bauer was concerned about Biethman's cash flow.
On November 25, 1990, Magna Bank renewed its preexisting loans with Biethman, *1317 adding additional collateral including the real estate located adjacent to Scott Air Force Base that was subject to United Fire's prior mortgage. At the time Magna Bank recorded its mortgage, it was aware of United Fire's prior mortgage on the same real estate, and Bauer had a copy of the September 13, 1990, agreement between Biethman and United Fire in its files.
United Fire rested its case, and Biethman made a motion for judgment in his favor. The grounds of the motion that are relevant to this appeal were (1) the note had been paid, and (2) the note and deed of trust did not contain future-advance clauses which were required for United Fire to secure payment of any amount over the initial $700,000 United Fire paid on behalf of ECF.
The trial court denied Biethman's motion, stating that it was satisfied that United Fire had presented sufficient evidence to show that Biethman and ECF owed United Fire over $700,000 on the six-month due date of the note; and that a future-advance clause was not essential to the promissory note and deed of trust, because the note was simply a six-month note secured by a real estate mortgage; and that on the six-month anniversary of the note, Biethman owed United Fire over $950,000, which was clearly in excess of the $700,000 face amount of the note. Additionally, the court found that the evidence was clear that at the time Magna recorded its mortgage in November 1990, it had actual knowledge of the fact of the agreement between Biethman and United Fire.
Implicit in the trial court's ruling on Biethman's motion was the finding that Biethman was not entitled to pay off the note simply by paying in at least $700,000 to United Fire. Rather, the trial court looked at the entire transaction and found that United Fire was allowed to apply direct payments from Biethman and indirect payments from the owners of the various projects to its total obligation, rather than to the note first.
Biethman called Mary Ann Schulien, ECF's bookkeeper, to testify. She identified a list of checks written on the special account, signed by Biethman and a representative of United Fire and made payable to United Fire. She testified that these checks totalled over $850,000, and that project owners had paid United Fire additional sums, so that the total amount paid to United Fire by or on behalf of Biethman was over one million dollars. Schulien testified that when she issued the checks out of the special account to United Fire, she considered them to be "payments towards the note." She testified that she was never told by anyone from United Fire that these payments did not reduce the balance due on the note.
Finally, Biethman testified that his understanding of the agreement with United Fire was that they were only going to pay bonded obligations and he would be responsible for paying unbonded obligations, that each job would stand on its own, and that if a job, whether bonded or not, was profitable, he could keep those funds to pay his bills. He did not testify as to the manner in which he was supposed to reimburse United Fire if any of the jobs were not profitable. His understanding of the purpose of the note and deed of trust was that they were "to help [him] pay those bonded bills." He stated that when he signed the checks to United Fire, he intended to pay off the note, and he did not intend the payments to be applied to his total obligation to United Fire. He wanted to get the note paid off first in order to get the deed of trust to his personal real estate cleared. United Fire never told him "in any way shape or form how those checks were being applied." He did not deny entering into the agreement, which specified that the note and deed of trust were to remain in force until the total obligation of United Fire was extinguished. Biethman never tried to inform United Fire that he had paid off the note, and he never requested a release of mortgage from United Fire.
The trial court found that the evidence was "absolutely clear" and that it went far beyond the preponderance necessary for United Fire to foreclose on the deed of trust. The trial judge stated that Biethman's argument that he had paid off the note was illogical and not supported by any case law of which the court was aware. The trial court entered judgment for United Fire on its countercomplaint, foreclosing the deed of trust and promissory note for $700,000. The *1318 court also determined that United Fire's mortgage held priority over Magna Bank's mortgage.
We now turn to the issues raised on appeal. For the sake of clarity, we discuss the issues only as they relate to Biethman, since Magna Bank adopted Biethman's arguments on appeal. Initially, Biethman argues that the trial court erred in admitting the agreement into evidence because United Fire did not attach a copy of it to its countercomplaint as required by section 2-606 of the Code of Civil Procedure (735 ILCS 5/2-606 (West 1992).) We find this argument meritless for several reasons.
First, section 2-606 requires, in pertinent part, that if "a claim or defense is founded upon a written instrument, a copy thereof * * * must be attached to the pleading." (Emphasis added.) (735 ILCS 5/2-606 (West 1992).) United Fire argues, and we agree, that they were not required to attach a written copy of the agreement to their countercomplaint because their claim was not founded upon the agreement, but rather, upon the promissory note and deed of trust. Those were attached to the countercomplaint, and no more than that was necessary. Biethman's argument that United Fire's claim was founded upon the agreement rather than the promissory note and deed of trust is conclusionary and not supported by the facts.
Second, United Fire complied with the pleading requirements of the Illinois Mortgage Foreclosure Law (735 ILCS 5/15-1101 et seq. (West 1992)), which requires only that a complaint in foreclosure attach copies of the mortgage and note secured thereby. (735 ILCS 5/15-1504(a) (West 1992).) There is no law that every relevant document which counsel seeks to introduce as an exhibit at trial must be attached to his pleading, and indeed, such a requirement would be unworkable and imprudent. Heuvelman v. Triplett Electrical Instrument Co. (1959), 23 Ill.App.2d 231, 161 N.E.2d 875.
Third, the agreement was relevant to the court's understanding of both of Biethman's defenses, payment and lack of consideration. Biethman's attorney admitted as much during trial. Moreover, it is well established that the construction of a mortgage involves the consideration of all of the instruments executed in furtherance of the parties' agreement and that the mortgage cannot be viewed in a vacuum but must be examined in light of the overall transaction between the parties. Peterson Bank v. Langendorf (1985), 136 Ill.App.3d 537, 90 Ill.Dec. 961, 483 N.E.2d 279.
Finally, this issue is more logically discussed in terms of the burden of proof at trial than in terms of which documents are necessary attachments to pleadings. Here, Biethman pleaded the affirmative defenses of lack of consideration and payment of the mortgage. In order for United Fire to establish a prima facie case of foreclosure, it was required only to introduce the deed of trust and promissory note, at which time the burden of proof shifted to Biethman to prove his affirmative defenses. (Foreman Trust and Savings Bank v. Cohn (1930), 342 Ill. 280, 174 N.E. 419.) Thus, while the agreement was relevant to the court's consideration of the entire transaction between the parties, it was not a necessary element of United Fire's prima facie case. It was necessary only to rebut the defenses raised by Biethman.
Biethman's next argument is that the trial court erred in denying his motion for judgment at the close of United Fire's case. Biethman's argument concerning this issue is twofold. First, Biethman contends that the evidence established that he paid more than $700,000 to United Fire and, therefore, he paid the mortgage. However, the evidence does not support his contention. The evidence established only that Biethman had written checks totalling over $700,000 on the parties' special account, not that he had paid anything on the promissory note. Biethman's construction of the facts assumes that United Fire was somehow required to apply his payments to the secured debt, rather than to the unsecured debt, which assumption is not supported by the law.
Where a debtor owes money to a creditor under more than one account or note, and the debtor does not specify the *1319 account or note to which a payment should apply, then the creditor has the right to apply the payment to the note or account of its choice under the doctrine of equitable application of payments. (B. Kreisman & Co. v. First Arlington National Bank (1980), 91 Ill.App.3d 847, 47 Ill.Dec. 757, 415 N.E.2d 1070.) "The general rule is that where a creditor holds both secured and unsecured debts of a debtor, he may apply payments made to the unsecured debts because it would be contrary to public policy to require a creditor to apply unspecified payments to secured debts, thereby depriving a creditor of his lien." Skach v. Gee (1985), 137 Ill. App.3d 216, 221, 91 Ill.Dec. 882, 484 N.E.2d 441, 444.
Here, although Biethman and ECF's bookkeeper said that they intended to pay off the note first, they did not specify that purpose on the checks to United Fire. Additionally, Biethman did not deny that he owed United Fire more than $700,000, but he merely argued that the amount over $700,000 was unsecured by his personal real estate. Moreover, the agreement specifically prohibited Biethman from paying off the secured debt, the mortgage, before paying off the unsecured debt, Biethman's total indebtedness to United Fire. Therefore, Biethman's argument that the evidence established that he paid the debt fails.
Biethman's final argument is that the trial court erred in denying his motion for judgment at the close of United Fire's case because the mortgage did not contain a future-advance clause, and therefore, Biethman argues: "[T]hose monies advanced in excess of the $700,000 face value of the Note are unsecured. Since over $700,000 has been repaid by ECF on the Note and Mortgage, [United Fire's] Note and Mortgage have already been satisfied. Thus, any balance due [United Fire] is unsecured and the lower court erred." Clearly, Biethman's argument concerning the lack of a future-advance clause is dependent upon his argument that he paid the note. The court entered judgment foreclosing the deed of trust only on the secured debt of $700,000 plus interest. Biethman is correct that in order to secure future advances under a mortgage document, the amount secured must be specified in the mortgage. (735 ILCS 5/15-1302(b)(1) (West 1992).) That is exactly what happened in this case.
United Fire recorded its trust deed as a mortgage secured by a promissory note for $700,000. Pursuant to the parties' agreement, United Fire paid sums far in excess of $700,000 for Biethman's bonded obligations, which excess sums were not secured by the promissory note and deed of trust. United Fire applied Biethman's payments to the unsecured debt, reducing it rather than the secured debt. After the six-month promissory note came due, United Fire foreclosed upon it and received a judgment limited to the amount of the secured debt of $700,000 plus interest and attorney fees. We agree with the trial court that, in this case, the lack of a future-advance clause in the trust deed was not fatal to the foreclosure.
For all of the reasons stated, we affirm the judgment of foreclosure.
Affirmed.
CHAPMAN and RARICK, JJ., concur.
