delivered the opinion of the court:
Plaintiffs, Thomas and Eileen Perkins, brought an action against defendants, James Collette, Adele Collette, and Century 21 Plaza Real Estate, for rescission of a real estate sales contract and damages. Plaintiffs alleged that James Collette, an agent of Century 21 *854Plaza, fraudulently represented that if they purchased a vacant lot which the Collettes owned, they would be able to build a house on the lot. The circuit court of Du Page County dismissed plaintiffs’ original and first amended complaints primarily on the basis that any misrepresentations made by James Collette were misrepresentations of law upon which plaintiffs were not entitled to rely. Plaintiffs contend on appeal that the trial court erred by concluding that Collette’s misrepresentations were ones of law, not fact, and by dismissing their complaints. We reverse and remand.
Plaintiffs filed a four-count complaint alleging fraud on February 5, 1987. The complaint also alleged a breach of fiduciary duty on the part of James Collette in his capacity as a real estate broker. The Collettes subsequently filed a counterclaim for installment payments allegedly due and owing under the contract. The trial court dismissed the complaint on September 22,1987.
Although the trial judge stated on the record that the above dismissal was with prejudice, he also stated that plaintiffs would have leave to file an amended complaint employing any legal theories not set forth in the original complaint. The trial judge denied plaintiffs’ motion to reconsider on October 19, but allowed plaintiffs leave to file an amended complaint within 45 days. Since dismissing a case with prejudice means that plaintiff will not be permitted to plead over and the litigation is terminated (O’Hara v. State Farm Mutual Automobile Insurance Co. (1985), 137 Ill. App. 3d 131, 133, 484 N.E.2d 834, 836), it is apparent that the trial judge mischaracterized the September 22, 1987, dismissal order. Accordingly, we will ignore that characterization and consider the September 22 order as a dismissal without prejudice.
Plaintiffs subsequently filed an amended complaint in which they alleged as follows. On or about September 26, 1981, plaintiffs met with James Collette at the Century 21 Plaza office in Villa Park. Plaintiffs told Collette that they wanted to purchase a vacant lot and build a home on the lot. Collette showed them a vacant parcel of land which was listed for sale by Century 21 Plaza. He informed plaintiffs that the lot was a suitable place to build a home. James and Adele Collette owned this parcel of land.
On October 3, 1981, plaintiffs executed a sales contract in which they agreed to purchase the lot for $14,000. Plaintiffs paid $2,000 in earnest money to Century 21 Plaza at this time. The parties held an interim closing on November 13, 1981, during which plaintiffs and the Collettes executed articles of agreement for deed. Plaintiffs paid an additional $5,216 at this time. After the closing, Thomas Perkins *855asked James Collette whether Perkins would be able to obtain a building permit for the lot. Collette told Perkins that it would be no problem for him to obtain such a permit.
Thomas Perkins requested an application for a building permit from Thomas Miller, the Du Page County supervisor of zoning enforcement, on September 9, 1983. Miller told Perkins that James Collette had previously submitted an application for a building permit for the subject property which had been denied and that the Perkins’ application would be denied as well. Upon discovering that they could not obtain a building permit for the property, plaintiffs sent the Collettes a notice of rescission of the articles of agreement for deed. On or about October 24, 1983, plaintiffs received a letter from the attorney for the Collettes. The letter stated that the Collettes had filed a lawsuit against the County of Du Page. According to the amended complaint, the lawsuit was still pending in the circuit court of Du Page County, and no progress had been made.
The amended complaint further alleged that James Collette knew that the vacant lot was not a suitable place to build a home and that plaintiffs could not obtain a building permit for the lot, but deliberately concealed these facts from plaintiffs. Collette was an employee of Century 21 Plaza and was acting as its agent.
Although the amended complaint did not incorporate the allegations of the original complaint, the six counts of the amended complaint are numbered V through X. Counts V and VI are directed against James Collette and seek rescission on the basis of unilateral mistake and mutual mistake. Counts VII and VIII are directed against Adele Collette and seek rescission on the same grounds. Count IX is directed against James Collette and requests damages and the imposition of a constructive trust as a result of his alleged fraudulent misrepresentations in violation of the Consumer Fraud and Deceptive Business Practices Act (Act) (Ill. Rev. Stat. 1987, ch. 12172, par. 261 et seq.). Count X is directed against Century 21 Plaza and is also premised upon alleged violations of the Act.
The circuit court dismissed plaintiffs’ amended complaint with prejudice in an order dated April 20, 1988. The Collettes’ counterclaim was still pending at this time. The trial court included the requisite language in the April 20 order to render it appealable pursuant to Supreme Court Rule 304(a) (107 Ill. 2d R. 304(a)). Plaintiffs filed a timely notice of appeal and subsequently filed an amended notice of appeal.
The amended notice of appeal states that plaintiffs are appealing from the September 22, 1987, order dismissing the original *856complaint, the October 19, 1987, order denying plaintiffs’ motion to reconsider the aforesaid dismissal, and the April 20, 1988, order dismissing their amended complaint. This court only has jurisdiction to review the latter order because it is the only order containing the requisite language trader Rule 304(a) (107 Ill. 2d R. 304(a)). Furthermore, by filing an amended complaint, plaintiffs waived any objection to the dismissal of their original complaint. (Foxer oft Townhome Owners Assoeiation v. Hoffman Rosner Corp. (1983), 96 Ill. 2d 150, 153-55, 449 N.E.2d 125, 126-27.) We will only review the trial court order dismissing the amended complaint.
Defendants’ motion to dismiss the amended complaint was made pursuant to section 2—615 of the Code of Civil Procedure (Ill. Rev. Stat. 1987, ch. 110, par. 2—615). Such a motion attacks only the sufficiency-of the complaint and should be decided solely upon the allegations set forth therein. (Schnidt v. Henehan (1986), 140 Ill. App. 3d 798, 801, 489 N.E.2d 415, 417.) The motion should only be granted if it is clear that plaintiffs cannot prove any set of facts under the pleading which would entitle them to the relief requested. (Schnidt, 140 Ill. App. 3d at 801, 489 N.E.2d at 417.) In their briefs on appeal, plaintiffs and defendants have referred to facts which were not alleged in the amended complaint. In reviewing the trial court’s dismissal order, we shall only consider the facts alleged in the amended complaint.
Two counts of plaintiffs’ amended complaint allege violations of section 2 of the Act (Ill. Rev. Stat. 1987, ch. 121½, par. 262). One of those counts is directed against James Collette as a result of his alleged misrepresentations, and the other is directed against Century 21 Plaza, Collette’s alleged employer at the time of the misrepresentations. Section 2 states in part as follows:
“Unfair methods of competition and unfair or deceptive acts or practices, including but not limited to the use or employment of any deception, fraud, false pretense, false promise, misrepresentation or the concealment, suppression or omission of any material fact, with intent that others rely upon the concealment, suppression or omission of such material fact, or the use or employment of any practice described in Section 2 of the “Uniform Deceptive Trade Practices Act,” approved August 5, 1965, in the conduct of any trade or commerce are hereby declared unlawful whether any person has in fact been misled, deceived or damaged thereby.” Ill. Rev. Stat. 1987, ch. I2IV2, par. 262.
Section 2 of the Act applies to intentional misrepresentations *857made by real estate brokers to prospective purchasers. (Stefani v. Baird & Warner, Inc. (1987), 157 Ill. App. 3d 167, 175, 510 N.E.2d 65, 70; Zimmerman v. Northfield Real Estate, Inc. (1986), 156 Ill. App. 3d 154, 168, 510 N.E.2d 409, 417.) The broker must have knowledge of the false, misleading, or deceptive nature of the information he conveys. (Zimmerman, 156 Ill. App. 3d at 168, 510 N.E.2d at 417.) Plaintiffs have clearly alleged facts establishing that James Collette, a real estate broker and agent of Century 21 Plaza, made misrepresentations to them and had knowledge that the information he was communicating to them was false.
Defendants assert, however, that the Act only applies to misrepresentations of material fact and that the alleged misrepresentations of James Collette were ones of law, not fact. Defendants rely largely upon the decision of this court in Hamming v. Murphy (1980), 83 Ill. App. 3d 1130, 404 N.E.2d 1026.
In Hamming, one of the sellers advised a buyer of certain real estate that all of the zoning “red tape” had been taken care of so as to permit the construction of apartments on the subject property. (Hamming, 83 Ill. App. 3d at 1132, 404 N.E.2d at 1028.) The court held that this could not constitute a fraudulent misrepresentation because it was a representation of law. The court stated that a party to a transaction is not generally entitled to rely upon a representation of law because both parties are presumed to be equally capable of knowing and interpreting the law. 83 Ill. App. 3d at 1135, 404 N.E.2d at 1030.
The Hamming rationale was applied in two cases cited by defendants to this court. In OBrien v. Noble (1982), 106 Ill. App. 3d 126, 435 N.E.2d 554, plaintiffs asserted that defendants negligently misrepresented in an advertisement describing a five-acre parcel of land for sale that one house could be built on the lot, when plaintiffs were subsequently unable to obtain a building permit for a house because of developmental restrictions in a local zoning ordinance. (O’Brien, 106 Ill. App. 3d at 127-28, 435 N.E.2d at 555.) The court stated “the facts concerning the zoning of the property were a matter of public record and readily available to plaintiffs” and held that defendants were not liable for negligent misrepresentation. 106 Ill. App. 3d at 130, 435 N.E.2d at 557.
This court applied the Hamming rationale in City of Aurora v. Green (1984), 126 Ill. App. 3d 684, 467 N.E.2d 610, a case in which the sellers allegedly told the buyers that a building was properly zoned for use as five residential units when it was actually located in a two-family residential zone and had been remodeled by the sellers *858without city approval. (City of Aurora, 126 Ill. App. 3d at 685, 467 N.E.2d at 611.) The court concluded that the buyers could not have reasonably relied upon the above representation because it concerned existing zoning laws and their application to the subject property. 126 Ill. App. 3d at 688, 467 N.E.2d at 613.
In City of Aurora, the court distinguished Kinsey v. Scott (1984), 124 Ill. App. 3d 329, 463 N.E.2d 1359. The defendant in Kinsey sold a five-unit building to plaintiff and was aware that plaintiff intended to occupy one of the units herself while renting out the other four. Defendant did not inform plaintiff that the fifth apartment had been constructed without a building permit and that he had been told by a building inspector after the unit was finished that it was too late to obtain a permit. (Kinsey, 124 111. App. 3d at 333, 463 N.E.2d at 1362.) The court held that defendant’s statement that the building was a five-unit building was a misrepresentation because it was not lawfully a five-unit building. (124 111. App. 3d at 336, 463 N.E.2d at 1364.) The court also concluded that the misrepresentation was one of fact rather than law, thus rendering Hamming inapplicable. 124 111. App. 3d at 339, 463 N.E.2d at 1366.
This court recently cited Kinsey in support of its holding in Tan v. Boyke (1987), 156 Ill. App. 3d 49, 508 N.E.2d 390. In Tan, plaintiff purchased two apartment buildings on adjoining lots. One of the buildings contained 35 units; the other contained 31 units. The construction permit for the 35-unit building only authorized defendant to build 31 units in that structure. Additionally, the building permit applications for both lots included the south 60 feet of the lot containing the 31-unit building. Defendant did not tell plaintiff about these discrepancies, which resulted in a greater density of housing units and less available parking than local zoning ordinances permitted. Tan, 156 Ill. App. 3d at 52, 508 N.E.2d at 392.
Defendant argued in Tan that the trial court erred in imposing liability on the basis of fraud because the alleged misrepresentations were ones of law rather than fact and because plaintiff had the opportunity to discover the true situation herself. (156 Ill. App. 3d at 56-57, 508 N.E.2d at 394-95.) The court responded to these arguments by noting the general rule that one who makes a deliberate misrepresentation with knowledge that it has misled another cannot escape liability by claiming that the other party could have discovered the fraud through the exercise of reasonable care. (156 Ill. App. 3d at 57, 508 N.E.2d at 395.) The determinative issue, according to the court, was whether, considering the facts which plaintiff knew or could have known had he exercised ordinary prudence, plaintiff had the right to *859rely upon defendant’s misrepresentations. 156 Ill. App. 3d at 58, 508 N.E.2d at 395-96.
Addressing the above issue, the court stated as follows in Tan:
“It is clear that only a complicated analysis of the plat of survey and the applicable zoning ordinances would have revealed to the plaintiff the irregularities in construction and the resulting illegality of the buildings. Without some indication that the buildings had been improperly or illegally constructed, it is unlikely that a reasonably prudent prospective purchaser would have undertaken so extensive an analysis of the ordinance. *** We conclude that the plaintiff reasonably and justifiably relied on the defendant’s silence.” 156 Ill. App. 3d at 58, 508 N.E.2d at 396.
The primary factor which distinguishes Hamming, O’Brien and City of Aurora from Kinsey and Tan is whether the seller’s misrepresentations could have been discovered merely by reviewing applicable zoning or building ordinances. In Tan, as we noted above, the court stated that defendant’s misrepresentations could only have been discovered through a complicated analysis of the plat of survey and applicable zoning ordinances. (Tan, 156 Ill. App. 3d at 58, 508 N.E.2d at 396.) In Kinsey, the court stated “there is nothing in the record to indicate that plaintiff herself might have discovered by the exercise of ordinary prudence that the basement apartment was not constructed according to the housing and building code.” Kinsey, 124 Ill. App. 3d at 338, 463 N.E.2d at 1365.
Considering only the facts alleged in the amended complaint, as we are required to do in evaluating a section 2 — 615 motion, we cannot determine whether plaintiffs could have discovered the alleged misrepresentations of James Collette merely by reviewing applicable zoning and building ordinances. The amended complaint alleged that James Collette told plaintiffs that the vacant lot was a suitable location for a home, even though Collette himself had been denied a building permit for the lot. It further alleged that plaintiffs subsequently discovered that they would be unable to obtain a building permit for the lot. The amended complaint contained no facts, however, which would conclusively indicate that plaintiffs could have discovered the alleged misrepresentations by merely reviewing local zoning or building ordinances or that plaintiffs, as a matter of law, were not entitled to rely upon Collette’s misrepresentations for any other reasons. The trial court therefore erred by dismissing the two counts based upon the Act.
In each of the remaining four counts of the amended complaint, *860plaintiffs seek rescission on the basis of unilateral or mutual mistake. Defendants contend that even if some or all of the parties mistakenly believed that a home could be built on the property, this was a mistake of law not fact and that rescission is therefore inappropriate. Defendants rely upon the holding in Kazwell v. Reynolds (1928), 250 Ill. App. 174.
In Kazwell, the court upheld the dismissal of a complaint which alleged that a real estate purchaser informed the seller that he intended to use the land for two businesses and that the seller and his attorney assured him that there were no restrictions on the land other than those appearing of record in the county recorder’s office. (Kazwell, 250 Ill. App. at 175.) Under a village ordinance, however, the property was zoned for residential use. The court stated that all individuals are supposed to know the law and held that the doctrine of mistake was not applicable under the circumstances. The court emphasized that ignorance of the law is no excuse. 250 111. App. at 178.
The case at bar is distinguishable from Kazwell. As we have previously indicated, it cannot be determined from the allegations of the amended complaint whether plaintiffs could have discovered that they would be unable to build a home on the land by merely reviewing applicable building and zoning ordinances. In Kazwell, a review of a local zoning ordinance would have made it clear that the buyer could not use the land for the desired purposes. This is not necessarily true in the instant case. The trial court erred by dismissing the four counts in which plaintiffs sought rescission on the basis of mistake, as well as the two counts based upon alleged violations of the Act.
Accordingly, the judgment of the circuit court of Du Page County is reversed and the cause remanded for further proceedings.
Reversed and remanded.
REINHARD, J., concurs.