
481 P.2d 30 (1971)
94 Idaho 72
Dave DALBY, Plaintiff-Respondent,
v.
Fred R. KENNEDY, Defendant-Appellant.
No. 10157.
Supreme Court of Idaho.
February 16, 1971.
Stephen Bistline, Sandpoint, for defendant-appellant.
Lyons & Hofmeister, Sandpoint, for plaintiff-respondent.
*31 McFADDEN, Justice.
This action was instituted by Dave Dalby, the plaintiff-respondent, to recover $905.18, allegedly due from Fred R. Kennedy, defendant-appellant, on an open account for goods sold and delivered by respondent to appellant between April 30, 1961, and March 8, 1963. By his answer appellant interposed a general denial. After trial the court sitting without a jury, entered its memorandum opinion (which was adopted as a part of the findings of fact), findings of fact, conclusions of law and judgment in favor of respondent for the balance of the account, plus interest. Kennedy has appealed from the judgment.
Between April 30, 1961, and March 8, 1963, when the goods were delivered, Dalby was a service station operator and bulk oil distributor for Signal Oil Company. During this period, appellant Kennedy was a contractor and was a stockholder in and manager of a corporation incorporated in 1953 as Kenmor-Marina, Inc., (hereafter referred to as Kenmor). This operation had previously been a partnership, and the other principal stockholder was Kennedy's former partner. Sometime prior to May, 1961, this corporation ceased to do business but it was never formally dissolved by court action. The stockholders divided the assets and obligations between themselves.
Following division of the assets of Kenmor, Kennedy commenced operating under a so-called family corporation designated as Kennedy Redevelopment and Construction Company. Stockholders in this corporation were primarily members of Kennedy's family. Later another corporation appeared in the picture, and this was designated as Lake Properties, Inc., in which Kennedy had an interest, along with others not members of his family.
Plaintiff's exhibit 1, admitted in evidence, is a series of fifteen pages of an account book. The first page is entitled "Kenmore-Marina" and also "Fred Kennedy." On the second page there appears "Kenmore-Marina" and "Fred Kennedy" with a line drawn through "Kenmore-Marina." All other pages are headed "Fred Kennedy." Various debit and credit entries are set out in these pages, with a balance struck after each entry. No question has been raised as to the accuracy of the individual items as posted on this account. The principal issue as presented by this appeal is the propriety of certain items which appellant contends were charges not against him personally, but for charges that were properly those of Kenmor or other corporations.
On July 25, 1961, there appears an item in the amount of $487.83 which was a debit charged against the appellant, designated as "assigned account." Another debit item appears on April 3, 1962, in the amount of $847.22. Both of these are included in the balances of the running account. Various payments were made on this account so that on the final entry of March 8, 1963, a balance of $905.18 appears.
The "assigned account" debit charge in the account of July 25, 1961, came about in the following manner. Dalby had been selling oil and petroleum products to Kenmor with the sales slips being consolidated and forwarded to Signal Oil. Consolidation of the charges was done in order that Kenmor could get certain discounts for bulk purchases. Signal Oil billed Kenmor and when the account was not paid after a certain period of time it was charged back to the distributor  Dalby  who in turn charged it back to the appellant. A series of "ageing sheets" of the Signal Oil Company dealing with customers of Dalby were admitted in evidence. These reflect that the account of June, 1961, shows $487.83 was owing by Kenmor and after the assignment in 1961 no money was shown owing by Kenmor.
Similarly, the "ageing sheets" of the Signal Oil Company show that in March, 1962, there was a balance of $847.22 due from Fred Kennedy. The account, exhibit 1, reflects an "assigned account" item charged against Kennedy in the amount of $847.22 on April 3, 1962.
*32 Appellant contends that the trial court erred in its findings, conclusions of law and judgment in regard to these two "assigned account" items. His contentions break down into two separate areas that require individual consideration. The first area is that pertaining to the assigned account originally charged to Kenmor in the amount of $487.83. During the trial it developed that after this account had been assigned by Signal Oil back to Dalby, it was included in the Kennedy account, and monthly statements reflecting this were submitted to the appellant. Over appellant's objection, Dalby testified that he had a conversation with appellant concerning this account, the substance of which conversation was that appellant agreed he was assuming this obligation personally after he and the other stockholder of Kenmor had divided the assets and accounts between them. Appellant objected to this testimony on the ground that under the provisions of I.C. § 9-505(2) such agreement of Kennedy to pay the debt of Kenmor had to be in writing. Appellant also argues that respondent's complaint was couched in language setting forth an account stated and if he was going to rely upon a promise to pay it was incumbent on Dalby to have pleaded such fact. Appellant assigns as error the trial court's "allowing evidence, over objection, of a promise to answer for the debt of the marina corporation" and further assigns as error "giving judgment against defendant for the marina account  not sustained by admissible competent evidence  barred by the Statute  not within any exception  and not based on any consideration moving to defendant."
Had appellant desired to question the validity of items in this account, he could have employed pre-trial discovery procedures to develop the issue. The record does not reflect that this was done. Objection was made to the admission in evidence of exhibits 1 and 2 (exhibit 1 being the statement of account, and exhibit 2 being a series of sales slips charged to Kennedy) on the ground that exhibit 1 contained the assigned account of Kenmor and billings of another corporation and exhibit 2 was incomplete. Further objection was made to testimony by respondent as to conversations he had with appellant concerning the Kenmor account, on the ground that any promise by appellant to pay this account was within the statute of frauds and it was indispensable that this be in writing. The trial court overruled these objections.
The trial court did not err in admitting these exhibits in evidence. They were properly identified and were material to the issue before the court, i.e. the account itself, of which the two assigned accounts were a part. Admission of the testimony concerning the agreement of appellant to pay the Kenmor account was not erroneous to the degree that it became prejudicial error, inasmuch as appellant was not barred from asserting his theory of the case, i.e. the applicability of I.C. § 9-505 as a bar to recovery. Appellant presented as a defense that any recovery by respondent of the $487.83 item originally charged to Kenmor was barred because there was no writing or note or memorandum of the agreement by Kennedy. The trial court considered this defense and held it not applicable under the facts of this case.
After the account had been assigned by Signal Oil to Dalby, appellant for over a year continued doing business with Dalby. During this period of time payments were made on the account and monthly statements were submitted to appellant. There is nothing in the record indicating that appellant directed how payments were to be applied by respondent. In such situation the general rule is that if the debtor does not specify to which debts the payments are to be applied, the creditor may apply a payment to any of the several debts owed him by such debtor. McCarty v. Sauer, 64 Idaho 748, 136 P.2d 742 (1943); Home Owner's Loan Corp. v. Stookey, 59 Idaho 267, 81 P.2d 1096 (1938). It is further generally held that a *33 creditor may apply a payment to an unenforceable claim, but not to an illegal one. Hollywood Wholesale Electric Co. v. John Boskin, Inc., 121 Cal. App.2d 415, 263 P.2d 665 (1953); 70 C.J.S. Payment § 61, p. 266. See McDougall v. Servel, 50 Idaho 9, 292 P. 590 (1930). From the account before the court it is evident that Dalby in applying payments to the account applied them to the balance at the time of payment, the effect of such application being to liquidate the older items first.
After Kennedy and his former associate in Kenmor divided the assets of that corporation and "split the deal and some of the larger accounts we split," Kennedy used these assets taken from Kenmor in his own bubiness. When he later told respondent that he would pay the Kenmor account, this became his original obligation within the meaning of I.C. § 9-506. See Mineau v. Imperial Dredge, Etc. Co., 19 Idaho 458, 114 P. 23 (1911). Although there is a conflict in the evidence as to appellant promising to pay the Kenmor account himself, the trial court found for Dalby on that issue, and such finding being supported by substantial evidence will not be disturbed by this court on appeal. I.C. § 13-219; I.R.C.P. 52(a); Montgomery Ward & Co. v. V-1 Oil Co., 78 Idaho 280, 301 P.2d 1106 (1956); Gardner v. Fliegel, 92 Idaho 767, 450 P.2d 990 (1969). We find no error on the part of the trial court in its application of the law to these facts.
The second portion of the case involves the assigned account in the amount of $847.22, appearing in exhibit 1 under date of April 3, 1962. Previously this account had been carried by Signal Oil Co. charged to Fred Kennedy, and when Dalby had the account assigned to him he reflected it in the open account charged to Fred Kennedy. Appellant contends that this particular account was for merchandise purchased by corporate employees of the Kennedy Redevelopment and Construction Company, and Lake Properties Corp., and that it was chargeable to these companies and not to himself. The trial court in its memorandum found
"At this time [subsequent to transfer of Kenmor assets], all purchases made by defendant or his family or employees were charged to defendant's account and plaintiff told defendant that he was dealing with him personally and not with any corporations or others with which defendant might be involved. Defendant made no objection to this. Thereafter when defendant, his family or employees of Kennedy Redevelopment and Construction Co. or Lake Properties, Inc., made purchases there was no designation or instruction made by the person ordering or receiving the product as to who[m] it was for or to whom it was to be charged. All was placed upon the account in defendant's name and defendant was billed therefor in that way. Defendant from time to time made payments upon this account as charged. Some payments were made from the named corporations and some from defendant. All payments were credited to defendant's account.
"* * * I find that plaintiff had advised defendant that he was selling only upon the personal credit and liability of defendant, that defendant knew this and continued to do business under that requirement, that there was thus a general line of credit established by defendant personally with plaintiff on behalf of defendant and the various corporations with which he was connected as a principal party, that knowing the above, thereafter defendant did not himself, or cause his family or corporate employees to, designate the particular party or entity to whom a particular purchase was to be charged."
The foregoing findings of fact by the trial court are sustained by the record and are conclusive in this court. The credit being extended to appellant individually, he cannot now complain, especially in view of the fact monthly statements were submitted to him reflecting these charges against his personal account.
Appellant asserts that his exhibit A is proof that Dalby knew he was selling to *34 a corporate entity. This exhibit is a statement by respondent dated May 8, 1962, addressed to Lake Properties, Inc., in the amount of $600 for gas, lubricants, service, etc., "for Granite Creek job." The trial court found this statement to have been made out at the special request of appellant so that he might present it to directors of Lake Properties, Inc., to obtain funds from that corporation to pay Dalby. The court further found that the billing was made out for the convenience of appellant in his intercorporate transactions. At most this exhibit presents a conflict with evidence submitted by Dalby and the explanation as to how it arose was accepted by the trial court. In such a situation this court is bound by the findings of the trial court inasmuch as the findings were sustained by competent and substantial although conflicting evidence. Gardner v. Fliegel, 92 Idaho 767, 450 P.2d 990 (1969).
The judgment of the trial court is affirmed. Costs to respondent.
McQUADE, C.J., and DONALDSON, SHEPARD and SPEAR, JJ., concur.
