By this action the plaintiff sues to recover the sum of $4,000, alleging that there came into the hands of the defendant the sum of $10,000, funds of the Idaho Placer Mining Company, the assignor of the plaintiff, and that of said sum the defendant expended the sum of $6,000 in building and erecting a certain dredge, and in purchasing tools and supplies; and that of said sum the defendant still has in his hands $4,000, for which he has failed and refused to account to the plaintiff. This complaint was filed in the district court of Washington county on April 12,1906. On July 23, 1906, the defendant filed an answer and counterclaim. In *298the answer the defendant admits that the sum of $10,000, funds of the Idaho Placer Mining Company, came into his hands, and that he expended the sum of $6,000 in building and erecting a certain dredge and in purchasing tools and supplies, and alleges “the facts to be, that he paid, laid out, and expended the whole of said $10,000 in the building and equipment of said dredge, etc., together with a further sum of $1,000, which more fully appears in his counterclaim.” He then denies that of the said sum of $10,000 he still has the sum of $4,000, or any other sum or amount whatever, for which he has failed or refused to account; and denies that there is now due, owing or unpaid, from the defendant to the plaintiff, the sum of $4,000 or any other sum. . He then sets up a counterclaim for $11,000, or $1,000 in excess of the amount furnished by the plaintiff’s assignor, no part of which, he alleges, has been paid; and a further counterclaim for the sum of $1,800, salary as superintendent in the construction of said dredge, for which he asks judgment. The plaintiff answered the counterclaim and denied the allegations thereof.
"With this condition of the pleadings, on September 26, 1906, a stipulation was entered into by the parties in which it was agreed that the action be referred to Honorable Stewart H. Travis, “to take proof and submit findings to the court, and that the findings should not be final or the judgment of the court, but that they be made for the assistance of the court in rendering his decision.” Afterward, and on February 7, 1907, no action having been taken before the referee, the defendant applied to the district court for permission to serve and file an amended answer. This application was resisted by counsel for the plaintiff, and on the same day was denied by the court.
This is assigned as error. The defendant made no showing to the trial court why it was necessary to file this amended answer, and offered no excuse for the delay, why such answer was not presented at an earlier date. It will be observed that the complaint was filed in said court on April 12, 1906, and the original answer on July 23, 1906, and the cause was referred on September 26, 1906, and the application to amend *299was made on February 7, 1907. The defendant baying made no showing to the court why this application was not made at an earlier day, or why it was necessary to amend this answer, this court cannot say that the trial court abused its discretion in denying the application to amend. Amendments rest largely in the discretion of the court, and unless the exercise of such discretion deprives the complaining party of some substantial right, it is not error. (Dunbar v. Griffiths, ante, p. 120, 93 Pac. 654; Small v. Harrington, 10 Ida. 499, 79 Pac. 461; Kindall v. Lincoln Hdw. Go., 10 Ida. 13, 76 Pac. 992; Palmer v. Utah & N. Ry. Co., 2 Ida. 382, 16 Pac. 553; Emeric v. Alvarado, 90 Cal. 444, 27 Pac. 356; Wixon v. Bevins, 91 Cal. 477, 27 Pac. 777.)
On March 30, 1907, the referee filed in the district court a report, reciting, among other things, that the 11th day of March, 1907, was set for the time of taking the testimony, and on said day, Ed. R. Coulter, Esq., appeared for the plaintiff, and Lot L. Feltham, Esq., for defendant; that the burden of proof was upon the defendant and that defendant refused to open the ease and introduce proof; that counsel for plaintiff moved as follows:
“Counsel for the defendant failing and refusing to introduce any proof in support of the allegations of his answer that defendant has expended the whole of the sum of $10,000 of the funds of the Idaho Placer Mining Company which came into his hands, thus pleading payment of the demand alleged by the plaintiff in his complaint to be due from the defendant to it, the plaintiff moves the court for a judgment upon the pleadings in this action for the following reasons:
“Because of the failure of the defendant to introduce any proof sustaining its contention upon the pleadings in this action, the plaintiff is entitled to judgment in the sum prayed for in this complaint.
“That this motion was sustained by the Referee, to which ruling the attorney for the defendant excepted.
“The referee therefore finds that the plaintiff is entitled to judgment in the sum of $4,000 and costs.”
*300Counsel for defendant moved to set aside this report of the referee, which was overruled by the court on April 17, 1907. On April 18, 1907, the plaintiff made a motion that the above cause be remanded back to the referee, with instructions to file an amended report, which motion was sustained by the court, and the referee was instructed to make full and complete findings of fact upon the issues raised by the pleadings, from the evidence already before the referee, and report to the court.
The denial of the motion upon the part of the defendant to set aside the report of the referee was error but was harmless, for the reason that afterward, on motion of the plaintiff, the cause was sent back to the referee with instructions to make a full report, doing what counsel for defendant had asked to be done by his motion. Afterward, to wit, on April 18, the referee made what he designates as an amended and supplementary report, in which he reports “that in pursuance of the stipulation of reference made on the 26th day of September, 1906,1 do now respectfully report to this Honorable Court and find as follows:
“1. That on the 11th day of March, 1907, was set by me for the taking of testimony; that on said day there were in attendance before me Ed. R. Coulter, Esq., attorney for the plaintiff, and Lot L. Feltham, Esq., attorney for the defendant. That a stipulation was entered into between the counsel for the plaintiff and counsel for the defendant employing a stenographer and providing for payment for the services of same, and providing for the payment of the per diem of the referee.
“2. That the burden of proof in said action was upon the defendant, and that the defendant refused to open the case and introduce any proof.
‘ ‘ 3. The counsel for the plaintiff moved as follows: ‘ Counsel for the defendant failing and refusing to introduce any proof in support of the allegations of his answer that defendant has expended the whole of the sum of $10,000, of the funds of the Idaho Placer Mining Company which came into his hands, thus pleading payment of the demand alleged *301by the plaintiff in his complaint to be due from the defendant to it, the plaintiff moves the court for a judgment upon the pleadings in this action for the following reasons: “Because of the failure of the defendant to introduce any proof sustaining its contention upon the pleadings in this action, the plaintiff is entitled to judgment in the sum prayed for in its complaint.”
“4. That this motion was sustained by the referee, to which ruling the attorney for the defendant excepted.
“The referee further finds that between the month of June, 1904, and the 19th day of March, 1906, there came into the hands of defendant as president and general manager of the Idaho Placer Mining Company $10,000 of the funds of said company to be used in constructing and building a dredge for said company.
“5. That of the said sum of $10,000 of the funds of The Idaho Placer Mining Company which so came into his hands, defendant expended the sum of $6,000 thereof in building and equipping a dredge boat for said company in Snake River, in Washington County, Idaho, near Olds’ Ferry, Idaho, and in purchasing tools and supplies therefor.
“6. That The Idaho Placer Mining Company is a corporation created under the laws of the State of Idaho, during the month of June, 1904; and that on the - day of March, 1906, the Idaho Placer Mining Company, duly and regularly sold, assigned and delivered unto the Idaho Placer Mining Company, Limited, the plaintiff in this action, all its property of every name and nature, both real and personal, including all accounts, choses in action and also including the moneys due from defendant, Charles Green, to The Idaho Placer Mining Company, being the balance of said $10,000 which so came into his hands and which was not expended by said Green for the use and benefit of said company.
“7. That the Idaho Placer Mining Company, Limited, is and during all of the times mentioned in the pleadings in this action, was, a corporation created and existing under the laws of the State of Idaho.
*302“8. That there is in the hands of the defendant, Charles Green, of the said sum of $10,000 of the funds of the Idaho Placer Mining Company which came into his hands to be expended in building said dredge boat, the sum of $4,000 which belongs to the Idaho Placer Mining Company, Limited, the successor in interest of The Idaho Placer Mining Company, all of which is still due, owing and unpaid.
‘ ‘ 9. That there was an utter and absolute failure on the part of the defendant to introduce any evidence sustaining any of the allegations contained in the separate answers and counterclaims of the defendant, or either or any of them on file in this action.”
“coNclusions oe law.
“As conclusions of law from the foregoing facts, the referee finds as follows:
“1. That the plaintiff is entitled to judgment against the defendant in the sum of $4,000 and costs.
“2. That the counterclaims of the defendant be dismissed and held for naught and that the defendant take and recover nothing thereunder.
“All of which is respectfully submitted.
‘‘Dated this the 18th day of April, 1907.
“STEWART H. TRAVIS,
“Referee.”
Counsel for defendant made a motion to set aside this amended report, assigning six different grounds:
First, because the referee took no proof, and did not comply with the stipulation of reference.
Second, that neither the referee nor the court made an order as upon whom the burden of proof rested.
Third, that the referee does not show in his finding or report that he had at any time determined or ordered the order of proof in said case, or made any order declaring upon whom the burden of proof rested.
Fourth, that the report does not show that the referee made any order requiring the defendant to assume the burden of proof.
*303Fifth, that the amended report and findings are not supported by evidence, and are unauthorized and unwarranted by law.
Sixth, that there are no facts to sustain the findings of fact and conclusions of law.
This motion was denied by the court, to which counsel for defendant excepted. On the 2d day of May, the district judge made findings of fact and conclusions of law and entered a decree thereon. The court adopted and approved the findings of fact and conclusions of law of the referee. Counsel for defendant excepted to the findings and decree of the court. Afterward a motion for new trial was made and overruled by the court, and this appeal is from the judgment and the order overruling the motion for a new trial.
Counsel for defendant contend that the referee and court both erred in holding that the burden of proof was upon the defendant. The complaint alleged that there came into the hands of the defendant the sum of $10,000, that he expended $6,000 and still has $4,000, for which judgment was asked. The answer admitted that the defendant received $10,000 and he expended $6,000, and alleged that he had expended all of said $10,000 and $1,000 in addition thereto. Also the defendant denied that he had in his hands the sum of $4,000 or any other sum, and denied that there is due the plaintiff the sum of $4,000 or any other sum.
We are unable to determine upon what theory the referee and court concluded that these denials would not put in issue the allegations of the plaintiff’s complaint. The defendant denied the allegations of the complaint, as to the amount in his hands, and his indebtedness to the plaintiff, and it was incumbent upon the plaintiff to prove such facts. The plaintiff could not recover under these denials without proving the facts showing the balance due. The stipulations of reference authorized the referee to hear the testimony and submit findings to the court. Under this stipulation, the referee had no authority whatever to pass upon any question of law or determine the question as to the burden of proof or upon whom' the affirmative rested. This was a matter for the court, but *304it appears that the referee determined that the affirmative was with the defendant, and this report was approved by the court. This was error, as under the denials the affirmative was with the plaintiff to prove his ease. The complaint alleged that defendant received from plaintiff’s assignor $10,000 and that he had expended for its use $6,000 and was indebted for the balance, $4,000. The defendant admitted receiving the $10,000, and alleged that he had expended the entire sum and $1,000 in addition. This put in issue the amount due and required the plaintiff to prove the facts showing the balance due. The affirmative and burden of proof was on the plaintiff. The answer is not one of payment, but a denial of the facts showing an indebtedness. (McIntyre v. Ajax Mining Co., 20 Utah, 323, 60 Pac. 553.) The report of the referee shows that the plaintiff made a motion for judgment on the pleadings which the referee sustained, and this was approved by the court. This was error, both on the part of the referee and the court. A judgment upon the pleadings results from the fact that the answer does not put in issue the allegations of the complaint, or where the pleadings show upon their face the party entitled to recover without proof. In other words, a judgment on the pleadings is allowable, not because of a lack of proof, but because of the lack of an issue. When a party moves for judgment on the pleadings, he not only for the purposes of his motion admits the truth of all the allegations of his adversary, but must also be deemed to have admitted the untruth of all his own allegations which have been denied by his adversary. (Walling v. Bown, 9 Ida. 184, 72 Pac. 960.) Where issues of fact are raised by the pleadings which require evidence to establish, before the court could intelligently determine whether such issues are with the plaintiff or defendant, it is error to enter judgment on the pleadings. (Alspaugh v. Reid, 6 Ida. 223, 55 Pac. 300; Coombs v. Collins, 6 Ida. 536, 57 Pac. 310; Mills Novelty Co. v. Dunbar, 11 Ida. 671, 83 Pac. 932.)
When this case went to the referee, he should have followed the stipulation. He had no authority to pass upon the right as to judgment on the pleadings. That was a matter for the *305court. The finding of the court that the sum of $10,000 came into the hands of the defendant, and that the defendant expended the sum of $6,000 and is indebted to plaintiff for the balance, $4,000, when the latter fact was denied by the answer and no evidence was offered by the plaintiff to support such allegation, leaves such finding without any evidence whatever to support it. It was the duty of the plaintiff in this case to prove the balance claimed to be due, which fact was denied by the answer, and it was the duty of the referee under the stipulation to report to the court the evidence and the findings on the evidence. If there was no evidence, the referee under the stipulation had nothing whatever to do but to report that fact to the court. Under the condition of the pleadings, it was the duty of the court, in the absence of proof upon the part of the plaintiff, to dismiss the plaintiff’s complaint. And if the defendant failed to offer proof to support his counterclaim, that should have been dismissed also. But in the absence of proof, the court was without any facts before it to support the findings made. The judgment in this case will be reversed and a new trial granted and the cause remanded. Costs awarded to the appellant.
Ailshie, C. J., and Sullivan, J., concur.