The plaintiff moves to strike out the answer and counter-claim of the defendant filed in the above stated cause on the ground that the answer discloses no legal defense, and that the connter-elaim fails to set forth a cause of action. The complaint alleges that the plaintiff is a municipal corporation of the State of New Jersey and that the defendant is the duly elected sheriff of Passaic county, and has been continuously sheriff of said county since November 14th, 1933; that by virtue of his office as such sheriff, it was his statutory duty to make to each purchaser of any lands sold by him, or other officer of his staff, under any writ of execution, a deed of conveyance for the lands so sold, and that it was the further statutory duty of such sheriff to charge and collect a fee of $10 for drawing and making such deed of conveyance to the purchaser of any lands sold, and that as such sheriff, defendant drew and made to such purchaser of lands sold by him under any writ of execution, a deed for *510the lands so sold, and charged and received a fee of $10 from each purchaser for making such deed.
The complaint further alleges that it was the statutory duty of the defendant, as such sheriff, to turn over and account to the county treasurer for the sole use of the plaintiff, for such fees received by him for drawing and making such deeds of conveyance; that the sheriff by statute is made personally liable to the county of Passaic for the payment to it of all such fees charged or collected; and that the sheriff by statute received in lieu of all fees or other compensation, an annual salary for his services from the county of Passaic.
The complaint further alleges that the sheriff neglected and failed to keep an account of all such fees and moneys received by him for the use of the county, for drawing and making deeds of conveyance, by virtue of any writ of execution, for the period from January 1st, 1934, to June 1st, 1935, and that he further failed, on or before the fifteenth day of each month during such period, to make a full and itemized statement and return, verified by oath, to the county treasurer of all such fees collected; that the plaintiff, the county of Passaic, has demanded of the defendant that he make such account and pay over said fees to it as required by law, but that the said sheriff has entirely neglected, failed and refused to do so.
The complaint further alleges that the defendant has made one thousand and thirty-one deeds of conveyance during the said period from January 1st, 1934, to June 1st, 1935, and that there is due and owing therefor from the defendant to the county of Passaic for said period, the sum of $9,261.62, with interest thereon according to law.
The defendant by his answer admits substantially all of the allegations of the complaint, except that he avers it was not his duty to pay over to the county treasurer the fees collected by him for drawing and executing sheriff’s deeds, and he denies that he is personally liable to the county of Passaic for the payment to it of such fees charged or collected.
He further denies that he received personally any part of said fee of $10 collected for drawing and executing sheriff’s *511deeds, and avers that all he has received since taking office is his salary as provided by law; he further denies that he neglected and failed to keep an account of all such fees for the period between January 1st, 1934, and June 1st, 1935, and denies that he failed, on or before the fifteenth day of each month, to make a full and itemized statement and return, verified by oath, to the county treasurer of all such fees collected; he denies that he has refused to account for such moneys and alleges that he told the board of freeholders of Passaic county at a meeting held in December, 1934, or January, 1935, he was paying such fees to a lawyer for drawing his deeds and taking the acknowledgments thereto; he admits he made and delivered one thousand and thirty-one deeds during the period from January 1st, 1934, to Juno 1st, 1935, but denies that there is due and owing from him to the county of Passaic the sum of $9,261.62, or any other sum.
As a separate defense, the defendant avers that he did not receive any part of said fee of $10 per deed collected by him upon the delivery of each sheriff’s deed, but that he paid said fee to Theodore Bosenberg, an attorney-at-law of this state, for his services in preparing each sheriff’s deed and taking the statutory oath and acknowledgment thereto; that the statutory fee for taking an affidavit is twenty-five cents, and for taking proof of acknowledgment on a deed is $1, which statutory fees, amounting to $1.25, were actually paid by the sheriff to such attorney-at-law.
Defendant in his separate defense further alleges that the employes of Ms office as sheriff of Passaic county had duties in their positions which required all of their time during the whole working day, and that, therefore, they were not able to perform their customary duties in the office and also prepare the sheriff’s deeds, and that the defendant thereupon employed the aforesaid attorney-at-law to prepare such deeds for him as sheriff, which he was required to execute and deliver to purchasers at sheriff’s sales; defendant in said separate defense further avers that the preparation of such sheriff’s deeds is essentially the work of a lawyer, and that as such *512sheriff, he determined that in the proper performance of his office as sheriff, it was his duty to have such sheriff’s deeds prepared by an attorney-at-law instead, to avert any liability to purchasers for the improper preparation and execution of such deeds; that defendant paid the aforesaid attorney-at-law all of said fee of $10 per deed to compensate said attorney-at-law for the preparation of said deeds, for the purchase of the necessary forms and for the lawyer’s services in taking the affidavit and acknowledgment required by law to be on each sheriff’s deed.
By way of counter-claim against the county of Passaic, the defendant alleges that the civil service employes in the sheriff’s office when he assumed the duties thereof, were kept so busy by their routine work that they did not have time within office hours to prepare the sheriff’s deeds; that defendant was advised that the preparation of such deeds is essentially the work of a lawyer, and that unless they were carefully and properly drawn, defects might be detected in titles to real estate and great liability might devolve upon the sheriff for errors in the drawing and execution of such, sheriff’s deeds; that defendant, not being an attorney-at-law, and not having sufficient help in the sheriff’s office to prepare or take acknowledgments to sheriff’s deeds, engaged the services of an attorney-at-law of his own selection, Theodore Rosenberg, and requested- said attorney-at-law to prepare all sheriff’s deeds for the office of the sheriff of Passaic county, and that the defendant agreed to pay him for such services, and for his services in taking each acknowledgment for the sheriff’s deeds, the sum $10 per deed, being the fee fixed by statute to be charged and received by the sheriff from each purchaser of lands at the time that the deed is delivered, which was a reasonable fee.
Defendant further alleges that said attorney-at-law did in fact prepare all such deeds mentioned in the complaint and the affidavits and acknowledgments required by law, and did, at his own expense, purchase the necessary prepared and printed forms, and furnish the stenographic and other clerical services, and took all the acknowledgments and affidavits *513to said deeds as an attorney-at-law under the authority of the statutes; defendant further alleges that the law of this state provides a fee of twenty-five cents for administering each oath, and a fee of $1 for taking proof of acknowledgment of a deed, and that of the said $10 fee paid by this defendant to said attorney-at-law for preparing each deed, taking the affidavit and acknowledgment thereto, the sum of $1.25 was provided by statute, and that the remainder of $8.75 represented the fees and charges of said attorney-at-law for the preparation of said sheriff’s deed, and that said statutory fee of $10 is a fair and reasonable fee to be paid by the sheriff for having said sheriff’s deeds prepared and the affidavits and acknowledgments thereto taken by a duly authorized officer.
Defendant further alleges that if it be determined that the sheriff should pay to the county treasurer the entire fee of $10 that he received upon delivery of the sheriff’s deeds, then the defendant, who has paid all of said moneys as received to the aforesaid attorney-at-law, counter-claims judgment against the plaintiff for $9,261.62, with interest thereon according to law.
On a motion to strike out a pleading on the ground that it does not disclose any cause of action, Supreme Court rule No. 40 is now equivalent, under our present practice, to a general demurrer at common law, and deals with matters of substance only. Savage v. Public Service Railway Co., 95 N. J. L. 432; 113 Atl. Rep. 252, E. & A., 1920, Gummere, C. J.
On this motion, plaintiff admits the truth of all the facts well pleaded in the answer, and all inferences of fact which can be legitimately drawn therefrom. Ahlemeyer v. Miller, 103 N. J. L. 617; 133 Atl. Rep. 880, E. & A., 1927, Kalisch, J.
Opon a demurrer, it is the well settled rule that judgment will be given against the party whose pleading is first defective in substance. Brehen v. O’Donnell, 34 N. J. L. 408, Supreme Court, 1871, Scudder, J.
Under our “Sale of Land act” (4 Comp. Stat., p. 4675), it is provided by section 7:
*514“That the sheriff or other officer, who by virtue of any writ of execution, shall sell any lands, tenements, hereditaments and real estate levied on, shall make to the purchaser thereof a deed of conveyance for the lands, tenements, hereditaments so sold.”
Chapter 95 of the laws of 1924, page 184 (1 Cum. Supp. Comp. Stat. 1911-1924, p. 1240), entitled, “An act fixing the fees of sheriffs for drawing and making deeds and bills of sale for property sold under execution,” provides as follows:
“For drawing and making a deed to a purchaser of real property, sold under execution, the sheriff shall be entitled to charge a fee of ten dollars.”
Pamph. L. 1906, p. 76; 4 Comp. Stat., p. 4643, entitled, “An act respecting the fees of surrogates, registers of deeds and mortgages, county clerks and sheriffs in certain counties of this state, and providing salaries for such officers,” provides in section 1:
“The fees, costs, allowances, percentages, and all other perquisites of whatever kind which by law the * * * sheriffs in counties other than counties of the first class of this state may receive for any official acts or services rendered by such * * * sheriffs, respectively, or by any assistant, or other person in their office or employment, for any acts done, or services rendered in connection with said offices, shall continue to be payable, and shall be received and collected by the said * * * sheriffs, respectively, for the sole use of their respective counties as public moneys belonging to the said counties; and shall be accounted for by said * * * sheriffs, and paid over as such in manner hereinafter provided.”
Section 2 of said act provides:
“The said * * * sheriffs shall respectively keep an account of all fees and moneys received by them pursuant to the provisions of this act for the use of their respective counties, and shall, on or before the fifteenth da}»- of each month, make a full and itemized statement and return verified by oath to the county collectors of their several counties, of the fees, costs, allowances, percentages and all perquisites of *515whatever kind received by them, or by any assistant or other person in their offices or employment, for any act done or service rendered in connection with said offices, and all sums which may have been charged or taxed, or which shall have accrued or become payable, for any such services during the month preceding the making of such statement; which statement shall be made under oath upon blanks containing a form of said statement, to be furnished to the said * * * sheriffs by the county collectors, respectively, and shall be filed in the offices of the county collectors, respectively, there to remain as public records. Such statements shall be forthwith audited by the county auditors, or other proper county officers, and on or before the twentieth day of each month the said * * * sheriffs shall, respectively, pay over the amount of such fees and moneys to the county collectors of their respective counties, under penalty of one hundred dollars for each day’s neglect to file such certificate, or to pay over such moneys, to be recovered in the name of the Board of Chosen Freeholders of such county where such default shall occur, for the use of the said county in an action upon contract in the Supreme Court, or in the Circuit Court of said county.”
Section 3 of said act provides:
“The said * * * sheriffs shall be personally liable to their respective counties for the payment of all such fees and costs as are mentioned in the first section of this act, * *
Section 4 of said act provides:
“* * * The said * * * sheriffs shall receive annual salaries as follows: In counties now or hereafter having a population of between two hundred thousand and three hundred thousand inhabitants, eight thousand dollars; * * * To be paid by the proper disbursing officer in equal semimonthly payments * * *. Said * * * sheriffs in any county in this state shall select and employ the necessary deputies, and chief clerks and all other employes, who shall receive such compensation as shall be recommended by said sheriffs * * * and approved by the Board of Chosen Freeholders of their respective counties, such compensation to be paii semi-monthly by the proper disbursing officer of said *516counties on warrant approved by the sheriffs * * Cum. Supp. Comp. Stat. 1925-1930, p. 1642, § 181-41; Pamph. L. 1927, ch. 204, p. 389.
The population of Passaic county under the 1920 federal census was two hundred and fifty-nine thousand one hundred and seventy-four, so that the statutory annual salary of the sheriff is fixed at $8,000. See Pamph. L. 1931, ch. 271, p. 681; N. J. Stat. Annual 1931, p. 105, § 48 *420M.
A careful study of the three statutes clearly shows that it is the statutory plan that the sheriff shall make to a purchaser a deed of conveyance for lands sold by him under a writ of execution and that his fee for drawing and making such deed to a purchaser of real property is fixed at $10; that this fee, payable to the sheriff, is received by him for the sole use of his county as public money belonging to the county and to be paid over and to be accounted for under oath to the county collector, on or before the fifteenth day of each month, and to be paid over by said sheriff to the county collector on or before the twentieth day of each month. The statute fixes a penalty for each day’s neglec-t to file such statement, or pay over such moneys, and gives to the board of chosen freeholders of the county a right of action to recover the penalty in either the Supreme or Circuit Court of the county, and in addition, makes the sheriff personally liable to the county for the payment of any such fees. The legislative plan, which was undoubtedly initiated to abolish the fee system for certain public officials, provides that the sheriff of Passaic county shall receive, in lieu of all other compensation, an annual salary of eight thousand dollars ($8,000), and further provides that while the sheriff may select and employ the necessary deputies, chief clerks and other employes to enable him to perform his official duties, their compensation must be recommended by the sheriff and approved by the board of chosen freeholders, and when the compensation is so fixed by the concurrent act of the sheriff and the tax-raising body of the county, the compensation ' shall be paid semi-monthly by the proper disbursing officer of the county, who, in the case of Passaic county, is its county treasurer, on warrant approved by the sheriff.
*517The attorney-at-law, Theodore Rosenberg, to whom the sheriff alleges he paid the statutory fee of $10, may have been selected and employed by the sheriff, but his compensation was never recommended by the sheriff to the board of chosen freeholders, nor approved by it, nor paid by the county treasurer on the sheriff’s warrant, as required by law.
The action of the sheriff in telling the board of freeholders, at a meeting held in December, 1934, or January, 1935, that he was paying such fees to a lawyer for drawing his deeds and taking the acknowledgment thereto, was not a compliance with his statutory duty, and to accept such a course of conduct as a legal justification for his acts, would place it within the power of the sheriff to nullify the legislative mandate contained in the Fee act of 1906, as amended.
Chief Justice Gummere, while considering the application of this act to the county clerk of Sussex county in the Supreme Court in 1922, in the case of Freeholders of Sussex v. Hopkins, 98 N. J. L. 301 (at p. 304), affirmed in 1924 by the Court of Errors and Appeals in 100 Id. 175, on the opinion below, pointedly said:
“To sum the whole matter up, a county official can no more escape responsibility for the performance of an act, which is required of him as such officer, by asserting that in performing it, he had first laid aside his official character, than a judge can escape responsibility for a decision rendered by him, by declaring that before announcing it, he had taken off his judicial robe.”
There can be no question in this case that the fees were received by the sheriff: by law, and that they were for his official acts or services. He is not asserting any right to retain these fees for his own use and benefit, and alleges that he has paid out those fees for the use and benefit of the county. Notwithstanding, this was a diversion of county funds, not a use of his own.
I think that this fact creates his personal liability. The state, through its legislature, imposed these services upon the sheriff, and in doing so, said to the sheriff:
“Account for these fees to your county or never more be *518officer of mine.” Freeholders of Passaic v. Slater, 85 N. J. L. 621; 90 Atl. Rep. 377, E. & A., 1913, Swayze, J.
Mr. Justice Swayze in that case held to this view regarding fees of county clerks in naturalization cases, notwithstanding the contrariety of opinions and decisions adverse to his views by courts for which he entertained the highest respect.
On the contention of the defendant that the board of chosen freeholders of Passaic county ratified the payments made by the sheriff to the attorney-at-law on the theory that since they had power to approve such payments before they were made, they could subsequently ratify them, the case of Demarest v. Inhabitants of New Barbadoes, 40 N. J. L. 604, E. & A. 1878, Dodd, J., is in point. In that case, the township sued its collector for the recovery of fees received by him beyond the fees allowed by law. The alleged illegal fees were charged in three bills, which were audited and passed by the township committee. It was contended that the collector could retain the fees because they were voluntary payments by the committee, with full knowledge of the facts, and without mistake or fraud. This contention was not permitted to prevail, because the Court of Errors and Appeals held that the powers of the township committee are only those conferred by statute. Mr. Justice Dodd (at p. 607), said:
“The committee and the collector both derive their powers solely from the legislature, and each is presumed to know the limit of the powers possessed by the other. The committee are the agents of the township only so far as they act within the express provision of the law. Payments made or sanctioned by them not authorized by legislative enactment are ultra vires, outside of their agency, and cannot bind their principals, the People. * * * The doctrines of acquiescence and voluntary payments * * * have no place, because the payments were not by the plaintiff now seeking recovery, nor by its sanction or approval.” See, also, Camden v. Varney, 63 N. J. L. 325; 43 Atl. Rep. 889, E. & A., 1899, Collins, J.
Defendant contends that the law laid down in the line of cases commencing with Demarest v. Inhabitants of New Bar*519badoes, supra; Troth v. Freeholders of Camden, 60 N. J. L. 190; 37 Atl. Rep. 1017, E. & A., 1897, and Freeholders of Passaic y. Slater, supra, is inapplicable on tbe ground that in each of those cases, the public official sought to retain the fees collected by him for his own use and benefit, while in this case, the sheriff paid out these fees for the use and benefit 'of the county. I am not impressed with this distinction, for in this ease, the sheriff used the county moneys, while not for his own personal benefit, in a manner which contravened a duty prescribed by statute, and exercised a dominion over the people’s money unauthorizel by law, no matter if the benefit inured to the county. His action was ultra vires, and he can derive no right therefrom to assert against the people of Passaic county, and is chargeable with knowledge of the invalidity and illegality of his acts. Clark v. Commissioners of Fire District No. 5, Woodbridge, 6 N. J. Mis. R. 732, Supreme Court, 1928, per curiam.
Defendant also seeks legal support of his acts in the class of cases which hold that when a municipal corporation has the right to enter into the given contract, such action may be thereafter ratified. Wentink v. Freeholders of Passaic, 66 N. J. L. 65; 48 Atl. Rep. 609, Supreme Court, 1901, Collins, J.; Bourgeois v. Freeholders of Atlantic, 82 N. J. L. 82; 81 Atl. Rep. 358, Supreme Court, 1911, Bergen, J.; Frank v. Board of Education of Jersey City, 90 N. J. L. 273; 100 Atl. Rep. 211, E. & A., 1916, Black, J.
But that argument is answered by the principle laid down in the case of Jersey City Supply Co. v. Jersey City, 71 N. J. L. 631, E. & A., 1904, where Mr. Justice Pitney stated the rule (at p. 633) :
“It is well settled, however, that a municipal corporation can act only through its authorized agents, and that where the powers of the corporation or its agents are subjected by law to restrictions with respect to the subject-matters of contract, or to restrictions as to the form and method of contracting that are limitations upon the power itself, the corporation cannot be held bound by either an express or an implied contract in defiance of such restrictions.”
*520Chief Justice Beasley iu the Supreme Court in 1874, in the case of Town of Hackettstown ads. Swackhamer, 37 N. J. L. 191, held that municipal corporations, in the absence of a specific grant of power, do not in general possess the capacity to borrow money, and that a note given by such corporation, for an unauthorized loan, cannot be enforced, even though the money borrowed has been expended for municipal purposes.
The contention of the defendant that it was necessary for him to employ an attorney-at-law for the proper drawing of the deeds of conveyance, and that it would be unlawful for him, or anyone in his office, to draw such deeds because of the provisions of the Unlawful Practice of Law act of this state, being chapter 138 of the laws of 1924 (Cum. Supp. Comp. Stat. 1911-1924, p. 874, § 52-214p), as amended by chapter 268 of the laws of 1928 (Cum. Supp. Comp. Stat. 1925-1930, p. 402, § 52-214t) may be disposed of by the observation that, assuming that law applied to this situation', he could have had the compensation of the attorney-at-law approved by the board of chosen freeholders, and his compensation paid in the manner provided by the Pee act of 1906, as amended.
I deem it unnecessary to consider the argument respecting chapter 214 of the laws of 1920 (Cum. Supp. Comp. Stat. 1911-1924, p. 1239, § 74-58), fixing the fees of masters in chancery, notaries public and commissioners of deeds for taking an acknowledgment of a deed, $1, and for taking an affidavit, twenty-five cents, for the purpose of deciding this motion.
The language of Mr. Justice Vann in the case of Village of Fort Edward v. Fish, decided in 1898 in the Court of Appeals of New York, 156 N. Y. 363; 50 N. E. Rep. 973, is apropos. In that case he said:
“The statute forbade the payment from the funds of the water board, and action forbidden by statute is void. A void act is no act and a void payment is no payment. Such payment is not voluntarily made by the corporation, but by its agent, in excess of his authority, and in defiance of its rights. It is not the act of the corporation itself, but of one, without *521authority, who assumed to act for it. * * * It is a matter of grave public concern to protect municipal corporations from the unauthorized and illegal acts of their agents in wasting the funds of the taxpayers. It is only with the utmost difficulty that municipal officers and agents can be kept within the bounds of their authority now, but once let it go forth as the settled law of the state that an illegal contract can become the basis of a lawful compromise entered into between the contractor and an agent guilty of the illegal action, and a new door will be open to municipal spoliation. * * * Sound public policy will not permit the courts to countenance this dangerous method of evading a statute, for it will always be done under the claim of good faith, and the fraud beneath will be hard to> discover.”
The counter-claim embraces a contingent set-oíf, i. e., if it be determined that the county is entitled to recover the funds diverted bjr reason of the fact that the defendant illegally employed the services of the attorney to do what he considered was necessary work of the office, it prays that he be permitted to set-off the same sum against that found due because it was used for the benefit of the county. This counter-claim is based upon a misconception. It seeks indemnity, but it is not such. The money used by the sheriff to pay Mr. Rosenberg was not his own money. It was the money belonging to the county. The liability of a municipality to indemnify an officer for money expended by him out of his own funds in the discharge of his official duties is supported by repeated adjudications. Barnert v. Paterson, 48 N. J. L. 395, Supreme Court, 1886, Knapp, J., and eases cited therein. In that case it appeared that the late distinguished Mayor Barnert of Paterson sought reimbursement of money paid by him out of his own pocket to employ counsel to defend him in a proceeding taken by the city to compel him, as mayor, to join in the execution of bonds which the city was about to issue, and which resulted in an adjudication that the mayor had acted properly. The late mayor paid his counsel for defending the action, and then brought his action to recover it back. That action was held to lie because it sought *522indemnity involving the disbursement of money out of pocket for which he was to be reimbursed. But in this case, the indemnity sought will not be granted because the sheriff was not possessed of a right to enforce his claims at law for the money paid by him for the services rendered. The employment of Mr. Rosenberg was unauthorized and for which no liability on the part of the county arose. The defendant was a volunteer with the county’s money. This court will not permit him, by this counter-claim, to rise to the position of a creditor.
The counter-claim will be stricken out because it does not set forth a cause of action.
As the answer in this case, in my opinion, does not set forth a defense, and an amended answer will not cure the situation (Lully v. National Surety Co., 106 N. J. L. 81; 148 Atl. Rep. 762, E. & A., 1929, Walker, C.); and the counterclaim discloses no cause of action, they should both be stricken out, and since the facts are such that the damages are admitted to be in the sum of $9,261.62, the plaintiff, the county of Passaic, is entitled to a rule for judgment in said sum, with interest. ■