
85 Cal.App.3d 637 (1978)
149 Cal. Rptr. 705
CITY AND COUNTY OF SAN FRANCISCO, Plaintiff and Appellant,
v.
FRANCESCO PACELLO et al., Defendants and Respondents.
Docket No. 41280.
Court of Appeals of California, First District, Division One.
September 27, 1978.
*640 COUNSEL
Thomas M. O'Connor, City Attorney, Edward C.A. Johnson, Dianne K. Barry and Diane L. Hermann, Deputy City Attorneys, Victoria M. Thomas and Jo Nell Biancalana, for Plaintiff and Appellant.
James J. Reilly for Defendants and Respondents.
OPINION
SWEENEY, J.[*]
Plaintiff, City and County of San Francisco, appeals from a judgment in favor of defendants in an action seeking to abate an alleged public nuisance.

STATEMENT OF FACTS
The subject structure had originally been built in 1925, authorized by a permit to construct a residential, one-family, two-story building. From 1929 on the building had the separate unit in it and it had two addresses. A 1921 zoning ordinance authorized two-family dwellings in R-1 districts as a permitted use (under certain conditions).
Defendants, the Pacellos, purchased the property, 152-154 Madrid Street on August 25, 1961. The property then consisted of a principal unit comprising the second-story level and an occupied housekeeping unit in the rear portion of the first or ground floor level, all a part of the original building.
On August 31, 1966, defendants applied for a building permit to "apply asbestos siding to rear" of their "existing two family dwelling." The permit was approved on condition that defendants apply for a permit to demolish the ground floor unit. On September 14, 1966, defendants filed a building permit application to apply asbestos siding and to "legalize building as a two-family dwelling." Ten months later, on July 13, 1967, the zoning administrator disapproved the permit application "because the proposal made in this application to legalize a second dwelling unit [in the building] is in violation of the density provisions applicable to this property, which has been zoned only for single family use since 1921. [¶] As city records indicate that the subject dwelling was constructed as a *641 single-family dwelling in 1921, and thus after the property was limited to single-family use, no second dwelling unit could have ever been legally added to the subject dwelling, the illegal dwelling unit must be removed. City records also indicate that you acknowledged receiving a copy of the residential building requirement report in July 1961, showing that the subject dwelling was built in 1925 as a one family dwelling, and that this occupancy was the legal use when you bought the property."
Defendants filed a timely appeal from the decision to the board of permit appeals (hereinafter Board).
The Board considered the appeal at its public hearing on August 7, 1967, and in addition, because the Pacellos could not speak English, the full Board conducted a site inspection of the property on August 11, 1967. At its hearing of August 14, 1967, the Board overruled the zoning administrator and ordered the permit issued and later denied his request for a rehearing.
The Board found that the zoning administrator had "erred in interpretation of the provisions of the Planning Code or abused his discretion as follows: The Board finds from evidence submitted and from a personal inspection of the subject premises as follows: ... [¶] The apartment at 154 Madrid Street, San Francisco, California, has been in existence for in excess of thirty (30) years; that the said apartment at 154 Madrid Street and the unit at 152 Madrid Street both conform to the provisions of the Planning Code and related ordinances and the Assessor of the City and County of San Francisco has been aware of the existence of two units at said premises. [¶] That the appellants in this matter were born in Europe and had no knowledge or were they aware of any illegality or legality of any units in the demised premises or of any technical requirements to legalize said units. That there are in excess of 200 units similar to the subject property which had been permitted to exist by technical compliance with the applicable ordinances."
On September 14, 1967, the zoning administrator was served with the order and decision of the Board. To date he has failed to comply; the Pacellos have not been granted the permit. Since the action of the Board, the transcript of its proceedings in the Pacello matter has been destroyed and the Pacellos have been living on their Social Security of $273 per month, stock dividends of $300 a quarter and $110 per month income from the questioned unit.
*642 As far as the record shows, the sole issue before the Board was the legality of the additional unit with respect to zoning and permitted use.
The appellant contends that the Board's decision and order are void for lack of jurisdiction. The trial court found that appellant's action is barred by the doctrine of laches.

JURISDICTION
(1) The traditional concept of jurisdiction as being the power to hear and determine concerning the subject matter and parties in a particular case has been broadened to include authority to do a particular thing in a particular manner. (See 16 Cal.Jur.3d, Courts § 43, p. 76, fn. 88.) Thus, where a statute requires a court to exercise its jurisdiction in a particular manner, or subject to certain limitations, or to follow a particular procedure, an act beyond those limits is in excess of the court's jurisdiction. (16 Cal.Jur.3d, Courts, § 43, p. 77 and cases cited in fn. 89.)
(2) It is the general rule that a final judgment or order is res judicata even though contrary to statute where the court has jurisdiction in the fundamental sense, i.e., of the subject matter and the parties. Lack of jurisdiction in the fundamental sense is essential, ordinarily, for collateral attack. (Pacific Mut. Life Ins. Co. v. McConnell (1955) 44 Cal.2d 715, 725 [285 P.2d 636] [app. dism. 350 U.S. 984 (100 L.Ed. 852, 76 S.Ct. 473)].)
The powers of the Board are set forth in the San Francisco City Charter, section 3.651 (formerly § 39):[1]
"Any applicant for a permit or license who is denied such permit or license by the department authorized to issue same, or whose license or permit is ordered revoked by any department, or any person who deems that his interests or property or that the general public interest will be adversely affected as the result of operations authorized by or under any permit or license granted or issued by any department, may appeal to the board of permit appeals. Such board shall hear the applicant, the permit-holder, or other interested parties, as well as the head or representative of the department issuing or refusing to issue such license or permit, or ordering the revocation of same. After such hearing and *643 such further investigation as the board may deem necessary, it may concur in the action of the department authorized to issue such license or permit, or, by the vote of four members, may overrule the action of such department and order that the permit or license be granted, restored or refused.
"The board of permit appeals shall have and exercise the following powers:
"(a) To hear and determine appeals where it is alleged there is error or abuse of discretion in any order, requirement, decision or determination made by the zoning administrator in the enforcement of the provisions of any ordinance adopted by the board of supervisors creating zoning districts or regulating the use of property in the city and county;
"(b) To hear and determine appeals from the rulings, decisions and determinations of the zoning administrator granting or denying applications for variances from any rule, regulation, restriction or requirement of the zoning or set-back ordinances, or any section thereof. Upon the hearing of such appeals said board may affirm, change, or modify the ruling, decision or determination appealed from, or, in lieu thereof, make such other additional determination as it shall deem proper in the premises, subject to the same limitations as are placed upon the zoning administrator by this charter or by ordinance." (Italics added.)
(3a) Clearly, the Board had the fundamental jurisdiction to hear the matter. Appellant's basic contention is that the Board did not have the power or jurisdiction to render the decision which it did. (4) "`"Jurisdiction [over the subject], being the power to hear and determine, implies power to decide a question wrong."'" (Signal Oil etc. Co. v. Ashland Oil etc. Co. (1958) 49 Cal.2d 764, 778 [322 P.2d 1], cited with approval in Hollywood Circle, Inc. v. Dept. of Alcoholic Beverage Control (1961) 55 Cal.2d 728 [13 Cal. Rptr. 104, 361 P.2d 712].)
(3b) Legal authority in support of the Board's decision is in city Planning Code section 202.1: "Principal Uses Permitted, R-1 Districts ... (c) A two-family dwelling, as regulated in R-2 districts; provided, that the second dwelling unit had been constructed prior to the effective date of this Code and provided that a Permit of Occupancy is issued by the Department of Public Works (Central Permit Bureau), within two (2) years of the effective date of this Code (May 2, 1960), to the effect that the two dwelling units conform to the provisions of this Code and related *644 ordinances, and provided that the Assessor has been notified of such improvements."
Appellant contends that the lack of jurisdiction is shown in that the Permit of Occupancy, applied for in 1967, could not be issued within two years of 1960 and that the Board had no authority to amend the code by extending the period. However, the Board found that there was substantial compliance, that the property conformed to the code and that the technical failure of the Pacellos to ask for the permit earlier constituted insufficient reason to deny them relief. This was an exercise of judicial discretion in applying the principle of substantial compliance which we do not find to be an act in excess of jurisdiction.

LACHES
The appellant challenges the trial court finding of laches on the following grounds: that laches was neither pleaded nor argued below, that there was no finding of detrimental reliance or change of position by the Pacellos caused by the appellant's delay in enforcement, and that no vested right to violate a zoning ordinance may be acquired by continued violations.
Laches was not pleaded by the respondents. It was, however, extensively argued in their trial brief.
(5) Laches is new matter which must ordinarily be pleaded to be cognizable by the court. (Victor Oil Co. v. Drum (1920) 184 Cal. 226, 243 [193 P. 243].) However, the trial court may find laches even where not pleaded if it appears from the complaint or the evidence. (Phoenix Mutual L. Ins. Co. v. Birkelund (1946) 29 Cal.2d 352, 363 [175 P.2d 5]; Akley v. Bassett (1922) 189 Cal. 625, 648 [209 P. 576].)
(6a) On its face, the complaint shows an unexplained delay of eight and one-half years between a cease and desist order by the zoning administrator and the institution of the present action. The delay also appears in the stipulated facts and the file of the Board.
(7) Delay alone will not constitute laches. It must also appear that some prejudice to the defendant was caused thereby. (Abbott v. City of Los Angeles (1958) 50 Cal.2d 438, 459 [326 P.2d 484].) (8) Whether laches occurred "is a question in the first instance for the trial court, and if its conclusion thereon can reasonably be held to find sufficient support *645 in the evidence, an appellate court should not interfere therewith." (Akley v. Bassett, supra, 189 Cal. at p. 648.)
(6b) The question becomes: is there substantial evidence of prejudice to the Pacellos occasioned by the appellant's delay. Respondents maintain that prejudice is shown in that Mr. Pacello retired on the strength of the rental income and the Pacellos have become accustomed to having that additional income. There is no evidence relating to Mr. Pacello's employment status, either at the time of the permit appeal or at the time of the trial below. While we recognize that terminating benefits a defendant has been receiving because the plaintiff has been delaying does not, of itself, constitute prejudice (Field v. Bank of America (1950) 100 Cal. App.2d 311, 314 [223 P.2d 514]), where the delay caused important evidence before the Board to become unavailable, prejudice is manifest. (Maguire v. Hibernia S. & L. Soc. (1944) 23 Cal.2d 719, 736 [146 P.2d 673, 151 A.L.R. 1062].) Such prejudice, plus the unexplained delay, constitutes laches. There is thus substantial evidence to support the trial court's finding thereof.
The appellant's final contention is that the doctrine of laches is inapplicable in cases of zoning violations because no vested right to violate such ordinances can be acquired by repeated violations. In neither case that appellant cites for this proposition was the defense of laches raised. Both Donovan v. City of Santa Monica (1948) 88 Cal. App.2d 386 [199 P.2d 51], and City of Fontana v. Atkinson (1963) 212 Cal. App.2d 499 [28 Cal. Rptr. 25], involved claims of estoppel.
(9) Although related to laches (Maguire v. Hibernia S. & L. Soc., supra, 23 Cal.2d 719), estoppel is a separate doctrine, with significantly more rigorous requirements. "Certain conditions are necessary as the basis for an estoppel: the party to be estopped must be apprised of the facts; the other party must be ignorant of the true state of the facts; the party to be estopped must have intended that its conduct be acted upon, or so act that the other party had a right to believe that it was so intended; and the other party must rely on the conduct to its prejudice. (Safway Steel Products, Inc. v. Lefever, 117 Cal. App.2d 489, 491....)" (Cal. Cigarette Concessions v. City of L.A. (1960) 53 Cal.2d 865, 869-870 [3 Cal. Rptr. 675, 350 P.2d 715].) Laches, on the other hand, requires only delay plus resulting prejudice. Estoppel cases, therefore, are of limited utility in determining the law of laches.
*646 (6c) The observation that no vested right to violate an ordinance can be acquired by continued violations was first made in an action challenging a zoning ordinance for unconstitutionality. (Acker v. Baldwin (1941) 18 Cal.2d 341, 346 [115 P.2d 455].) So the term "vested right" was used in the sense of "property invoking the protections of due process," or "contract right that must not be impaired." This means that the rule has no application to whether or not laches can arise in a zoning case.
In Donovan, supra, no estoppel could arise because the defendant knew at all times that his actions were in violation of the law. He obtained a permit to build a single family residence, and built one. Over the next several years he modified the building into a 24-unit apartment house. Most of the work was done without building permits. Although the court made the true observation that mere delay in enforcement does not create an estoppel, perhaps the crux of its decision was that "it is obvious that appellants at no time exercised that measure of good faith which would entitle them to invoke the doctrine of estoppel against respondents." (88 Cal. App.2d at pp. 395-396.)
In contrast, the Pacellos bought the house with the belief that its use was lawful. They performed no illegal alterations. Even though the problem of the additional unit was brought to their attention in 1967, they had good reason to believe that it had been solved by the Board's order and decision. The subsequent inaction of the city and county may or may not raise an estoppel, but it does constitute laches.
(10) It is a settled principle that equitable defenses will not ordinarily be invoked to defeat a policy adopted for the public protection. (City of Fontana v. Atkinson, supra, 212 Cal. App.2d at p. 508.) This principle was cited and applied in People v. Department of Housing & Community Dev. (1975) 45 Cal. App.3d 185 [119 Cal. Rptr. 266]. The People, through the district attorney, brought a mandamus action against the department for failure to fulfill the requirements of the California Environmental Quality Act before it issued a permit to the real party in interest to build a mobile home park. The People sought to have the permit rescinded. Even though the 180-day statute of limitations on the suit had not yet run, the trial court found that the action was barred by laches. The finding was upheld on appeal. The appellate court noted the strong public policy for environmental protection, but found that the presence of public interest was not a bar to equitable defenses. Rather, a weighing process would ascertain whether the injustice to be avoided was sufficient to counterbalance the effect of the defense upon a public interest.
*647 The real party in interest had spent $40,000 in reliance upon the permit before the action was brought and had acted in good faith throughout. Observing that the proposed park had aroused no opposition and was in accord with the zoning, the court held that the prejudice to the real party in interest was sufficient to allow the defense. The court was also influenced by the fact that both the petitioner and the respondent were agencies of the State of California. It seems patently unfair for the state to give with one hand and to take away with the other. (People v. Department of Housing & Community Dev., supra, 45 Cal. App.3d at pp. 197, 200.) In the instant case it is the city and county, acting through the city attorney, seeking to retake what it, through the board of permit appeals, had long since given.
It is clearly unjust to allow the city and county to attack the Board's decision upon which the Pacellos have been relying for eight and a half years.
We affirm the trial court's judgment.
Racanelli, P.J., and Newsom, J., concurred.
NOTES
[*]   Assigned by the Chairperson of the Judicial Council.
[1]  We may take judicial notice of the provisions of the city charter and municipal code. (Evid. Code, §§ 452, subd. (b), 459; Clark v. Patterson (1977) 68 Cal. App.3d 329, 334, fn. 5 [137 Cal. Rptr. 275]; City of Los Angeles v. Wolfe (1971) 6 Cal.3d 326, 331, fn. 2 [99 Cal. Rptr. 21, 491 P.2d 813].)
