
169 Cal.App.3d 529 (1985)
215 Cal. Rptr. 224
IONE DOMINIQUE LOMBARDO, Plaintiff, Cross-defendant and Appellant,
v.
SANTA MONICA YOUNG MEN'S CHRISTIAN ASSOCIATION, Defendant, Cross-complainant and Respondent.
Docket No. B009237.
Court of Appeals of California, Second District, Division Seven.
June 21, 1985.
*535 COUNSEL
Joseph Edward Hitzman for Plaintiff, Cross-defendant and Appellant.
Levin & Freedman and Marvin E. Levin for Defendant, Cross-complainant and Respondent.
OPINION
LILLIE, P.J.
Plaintiff and cross-defendant Ione Lombardo appeals from summary judgment entered against her and in favor of defendant and cross-complainant Santa Monica Young Men's Christian Association (Y.M.C.A.).[1]

PROCEEDINGS IN TRIAL COURT
Only the third cause of action of the complaint was directed against defendant Y.M.C.A.[2] That cause of action (imposition of constructive trust on property devised by will) alleged: In July 1982 Clara Hollowell died leaving a will executed in 1979 wherein she devised to defendant real property at 938 Second Street, Santa Monica (the property). Plaintiff filed in the probate proceeding a creditor's claim for $222,770 which included $840 as rent for the property which the executor of the estate wrongfully collected from plaintiff in view of the decedent's promise to plaintiff that she could occupy an apartment on the property rent-free for so long as she chose; and specific performance of decedent's promise to devise the property to plaintiff, or alternatively damages of $200,000 (the estimated value of the property). The executor rejected the claim. From September 21, 1981 to June 8, 1982, at the express request of the decedent and upon her express promise to pay the sums and do the other things described in the claim, plaintiff performed the services and did the things described in the claim. Prior to November 10, 1981, plaintiff and decedent entered into an oral contract *536 "memorialized in part" by a writing dated November 10, 1981, and signed by decedent. By the terms of said contract plaintiff agreed to supply personal services to decedent and decedent agreed to devise the property to plaintiff. The contract "was just and reasonable as to decedent" and the "consideration accruing to decedent was adequate" in that she desired to reward plaintiff for past services, spiritual assistance, help and friendship and had need of the future personal services plaintiff agreed to supply. In reliance on the contract plaintiff performed numerous and varied services for decedent from September 21, 1981 to June 8, 1982, and thus has performed all conditions, covenants and provisions required of her by the contract. Plaintiff has no adequate remedy at law in that the writing of November 10, 1981, does not qualify as a valid will. Attached to the complaint, and incorporated therein by reference, were copies of the writing of November 10, 1981, and of a writing dated October 1981 which was the basis of plaintiff's claim of the right to reside rent-free in the property.
Defendant answered the complaint and cross-complained for declaratory relief. The cross-complaint sought a declaration that plaintiff and decedent did not enter into an oral contract or a written contract whereby decedent agreed to devise the property to plaintiff; that plaintiff is not the beneficiary of a constructive trust on the property; and that the writing of October 1981 did not give plaintiff any possessory right to occupy the property.
After plaintiff answered the cross-complaint defendant moved for summary judgment in its favor on the complaint and for an order determining that the following issues in the cross-complaint are without substantial controversy: plaintiff's claim of the right to live rent-free on the property after decedent's death is barred by her failure to file a creditor's claim in decedent's estate asserting that right; plaintiff is not entitled to the equitable remedy of declaratory relief in her favor because the equities favor defendant. The motion was granted. Judgment was entered ordering that plaintiff take nothing as against defendant; that plaintiff is not entitled to a declaration that a constructive trust be imposed for her benefit against the property; and that plaintiff has not acquired a possessory right to occupy the property rent-free for any period following the death of decedent.

DISCUSSION

I
(1a) In its answer to the complaint defendant alleged, as an affirmative defense, that the alleged oral agreement between plaintiff and the decedent *537 is invalid under the statute of frauds. Defendant also made that argument in support of its motion for summary judgment.
At the time the oral contract to devise property allegedly was made, Civil Code section 1624 (statute of frauds) provided in pertinent part: "The following contracts are invalid, unless the same, or some note or memorandum thereof, is in writing and subscribed by the party to be charged or by his agent: ... [¶] 6. An agreement which by its terms is not to be performed during the lifetime of the promisor, or an agreement to devise or bequeath any property, or to make any provision for any person by will; ..."[3] (Italics added.) (2) The statute of frauds does not apply where the plaintiff is entitled to the imposition of a constructive trust, for such a trust arises by operation of law. (Briggs v. Nilson (1964) 226 Cal. App.2d 342, 346 [38 Cal. Rptr. 68].)
(1b) The purpose of the within constructive trust action is to enforce an oral contract to devise property, in equity, by quasi-specific performance. (See Dini v. Dini (1961) 188 Cal. App.2d 506, 513 [10 Cal. Rptr. 570].) (3) "The relief which may be granted in an action for quasi-specific performance of a contract to bequeath or devise property is the imposition of a constructive trust upon the property in favor of the promisee-plaintiff. It differs from the relief which would be available in a traditional specific performance action, and the remedy bears a different name, because the court cannot compel the making of a will." (Porporato v. Devincenzi (1968) 261 Cal. App.2d 670, 674 [68 Cal. Rptr. 210].) (4) The elements requisite to relief in such an action are: (1) a contract sufficiently definite in its terms to be enforced; (2) that the contract was just and reasonable; (3) that plaintiff performed his side of the bargain; (4) that the promisor failed to perform; (5) that the contract was supported by adequate consideration; (6) that the remedy at law is inadequate; and (7) where the contract was oral, the complaint also must allege that defendant is estopped to rely on the statute of frauds because failure to enforce the contract would result in either unconscionable injury to plaintiff or the unjust enrichment of defendant. (Porporato v. Devincenzi, supra, 261 Cal. App.2d at pp. 674-675.) (1c) The complaint in the present action did not allege, either expressly or by implication from facts which were alleged, that defendant is estopped to rely on the statute of frauds to establish the invalidity of the alleged oral contract whereby decedent agreed to devise the property to plaintiff. Accordingly, the complaint fails to state a cause of action for imposition of a constructive trust on the property effecting quasi-specific performance of the contract.
*538 (5), (6) (See fn. 4.) Failure to state a cause of action is a proper ground for granting summary judgment[4] since "a motion by a defendant under section 437c of the Code of Civil Procedure necessarily includes a test of the sufficiency of the complaint.... Motions for summary judgment in such situations have otherwise been allowed as being in legal effect motions for judgment on the pleadings. [Citation.]" (C.L. Smith Co. v. Roger Ducharme, Inc. (1977) 65 Cal. App.3d 735, 745 [135 Cal. Rptr. 483]; original italics. See also Slaughter v. Legal Process & Courier Service (1984) 162 Cal. App.3d 1236, 1245-1246 [209 Cal. Rptr. 189]; Stance v. Jackson (1984) 155 Cal. App.3d 838, 844 [202 Cal. Rptr. 480]; Barnett v. Delta Lines, Inc., supra, 137 Cal. App.3d 674, 682; Brown v. Critchfield (1980) 100 Cal. App.3d 858, 862, fn. 1 [161 Cal. Rptr. 342]; Bowden v. Robinson (1977) 67 Cal. App.3d 705, 710 [136 Cal. Rptr. 871].) Inasmuch as summary judgment on the complaint is sustainable on that ground, we need not determine whether a triable issue of fact exists regarding plaintiff's right to the imposition of a constructive trust based on the alleged oral agreement. (See Slaughter v. Legal Process & Courier Service, supra, 162 Cal. App.3d at pp. 1244-1245.)
(7a) The complaint alleged that the oral contract whereby decedent agreed to devise the property to plaintiff was "memorialized in part" by a writing dated November 10, 1981, and signed by decedent. Thus, plaintiff apparently relies on a written contract, as well as an oral contract, as the basis for imposition of a constructive trust. The writing of November 10, 1981 reads:[5]
"Nov. 10, 81
"To whom it may concern:
"In gratitude to Ione Dominique Lombardo for her dear friendship, love & many services rendered for my comfort & welfare it is my sincere desire that she remain in house at 938 2nd St. Upon my death I bequeath to her the said property at 938 2nd St. & an allowance to feed the pets.
/s/ Clara C. Hollowell"
(8) In order to satisfy the statute of frauds a written note or memorandum of a contract must state with reasonable certainty (1) each party to the *539 contract, (2) the subject matter to which the contract relates, and (3) the terms and conditions of all promises constituting the contract and by whom and to whom the promises are made. (Ellis v. Klaff (1950) 96 Cal. App.2d 471, 476-477 [216 P.2d 15]; 1 Witkin, Summary of Cal. Law (8th ed. 1973) Contracts, § 206, p. 187.) (7b) The writing of November 10, 1981, fails to meet the third requirement inasmuch as it contains no promise by either the decedent or plaintiff.
(9) Where a writing discloses no promise or agreement and cannot be made clear as to its significance without resort to parol evidence, it is inadequate to satisfy the statute of frauds. (Franklin v. Hansen (1963) 59 Cal.2d 570, 574 [30 Cal. Rptr. 530, 381 P.2d 386].) (10) "The parol evidence rule operates to bar extrinsic evidence which contradicts the terms of a written contract. [Citation.] It `is not a rule of evidence but is one of substantive law. It does not exclude evidence for any of the reasons ordinarily requiring exclusion, based on the probative value of such evidence or the policy of its admission. The rule as applied to contracts is simply that as a matter of substantive law, a certain act, the act of embodying the complete terms of an agreement in a writing (the `integration') becomes the contract of the parties. The point then is, not how the agreement is to be proved, because as a matter of law the writing is the agreement. Extrinsic evidence is excluded because it cannot serve to prove what the agreement was, this being determined as a matter of law to be the writing itself.' (Italics in original.) [Citations.] (11) [¶] In contrast to the rationale of the rule barring parol evidence, the `Purpose of the statute of frauds is to prevent fraud and perjury with respect to certain agreements by requiring for enforcement the more reliable evidence of some writing signed by the party to be charged....' [Citation.] Thus the statute of frauds excludes proof of certain types of agreements which are not sufficiently evidenced by a writing. [Citation.] Every material term of an agreement within the statute of frauds must be reduced to writing. No essential element of a writing so required can be supplied by parol evidence." (Riley v. Bear Creek Planning Committee (1976) 17 Cal.3d 500, 508-509 [131 Cal. Rptr. 381, 551 P.2d 1213]; latter italics added. See also Ellis v. Klaff, supra, 96 Cal. App.2d 471, 477; 1 Witkin, op. cit. supra, § 204, pp. 184-185.)
(12) Where no extrinsic evidence bears upon the interpretation of a contract, its construction becomes a matter of law. (Yamanishi v. Bleily & Collishaw, Inc. (1972) 29 Cal. App.3d 457, 462 [105 Cal. Rptr. 580].) (7c) Inasmuch as parol evidence was not admissible to supply the missing element of the terms and conditions of the respective promises of decedent and plaintiff, the sufficiency of the November 10, 1981 writing to satisfy the statute of frauds presented an issue of law which the trial court was authorized *540 to determine in the summary judgment proceeding. (See Blackwell v. Phelps Dodge Corp. (1984) 157 Cal. App.3d 372, 376 [203 Cal. Rptr. 706].) The court properly resolved that issue in favor of defendant. The writing in question does not qualify as a memorandum of contract within the meaning of the statute of frauds; it sets forth no promises by either the decedent or plaintiff, but merely expresses decedent's intention or desire to devise the property to plaintiff in appreciation of plaintiff's friendship for the decedent and her rendition of services to decedent. Accordingly, the writing furnishes no basis for the imposition of a constructive trust on the property in plaintiff's favor.

II
(13a) The judgment declares that plaintiff did not acquire a possessory right to occupy the property rent-free following the death of decedent. Plaintiff's claim of such right was based on a writing dated October 1981. That writing, entirely in plaintiff's handwriting except for the decedent's signature, reads:
"Oct 1981
"To whom it may concern:
"I entrust all my banking to Ione Dominique Lombardo.
"I have complete & utter trust in her to care for my well being.
"She is to rent & care for apts. to remain rent free at 938 2nd St apt. D so long as she chooses.
/s/ Clara Hollowell"
(14) In her declaration in opposition to the motion for summary judgment plaintiff stated that by the above writing decedent transferred to plaintiff a life estate in the property. The trial court properly sustained defendant's objection to such evidence on the grounds that it constituted a legal opinion of a lay witness and further was not relevant to any issue in the action inasmuch as plaintiff did not claim a life estate either in her complaint or in her answer to the cross-complaint. (See Evid. Code, §§ 350, 800; Pond v. Insurance Co. of North America (1984) 151 Cal. App.3d 280, 289 [198 Cal. Rptr. 517].) (13b) No other evidence bearing on the October 1981 writing was presented by either party. Accordingly, the construction of that writing likewise presented an issue of law determinable in the summary judgment proceeding. (See Blackwell v. Phelps Dodge Corp., supra, 157 Cal. App.3d 372, 376; Yamanishi v. Bleily & Collishaw, Inc., supra, 29 Cal. App.3d 457, 462.)
(15) Where no extrinsic evidence is presented in the trial court on the issue of the meaning of contractual language, the appellate function is the *541 same as that of the trial court, i.e., to arrive at a reasonable interpretation of the language in keeping with applicable rules of construction. (McKee v. State Farm Fire & Cas. Co. (1983) 145 Cal. App.3d 772, 775 [193 Cal. Rptr. 745].) (16) A contract must be considered as a whole and construed to give meaning to all of its parts if reasonably practicable. (Civ. Code, § 1641; Vale v. Union Bank (1979) 88 Cal. App.3d 330, 336 [151 Cal. Rptr. 784]; Masonite Corp. v. Pacific Gas & Electric Co. (1976) 65 Cal. App.3d 1, 8 [135 Cal. Rptr. 170].) (17), (13c) Viewed in accord with this rule of construction the writing of October 1981 appears to create an agency, the relation that results from the act of one person, the principal, who authorizes another, the agent, to conduct one or more transactions with one or more third persons and to exercise a degree of discretion in effecting the principal's purpose. (Workman v. City of San Diego (1968) 267 Cal. App.2d 36, 38 [72 Cal. Rptr. 509].) The opening line of the writing ("to whom it may concern") indicates that the writing is to be shown to third persons; the first paragraph gives plaintiff broad authority to conduct decedent's banking; the second paragraph sets forth decedent's reason for conferring such authority; the third paragraph authorizes plaintiff to care for and rent apartments and to remain rent-free in the property "so long as she chooses." (18) While consideration is not essential to the creation of an agency (Housewright v. Pacific Far East Line, Inc. (1964) 229 Cal. App.2d 259, 265 [40 Cal. Rptr. 208]), consideration here is expressed in the form of plaintiff's rent-free occupancy of her apartment.
(19) An agency is terminated by the death of the principal unless the power of the agent is coupled with an interest in the subject of the agency. (Civ. Code, § 2356, subd. (a)(2).) The requirements for the creation of an agency coupled with an interest are (1) that the agency be held for the benefit of the agent and not the principal, (2) that the agency is created to secure the performance of a duty to the agent or to protect a title in him, and (3) that the agency is created at the same time the duty or title is created or is created for consideration. (Becket v. Welton Becket & Associates (1974) 39 Cal. App.3d 815, 820 [114 Cal. Rptr. 531].) (13d) The first two requirements are not met in the present case. Accordingly, the death of the decedent effected the termination of the agency, including plaintiff's right to continue receiving compensation for her services as agent in the form of rent-free occupancy of her apartment. (20) Also pertinent is the principle that "`[i]f a person occupies premises belonging to his employer as a part of his compensation, he has no right to continue his occupation of the premises on the termination of his employment....'" (Eichhorn v. De La Cantera (1953) 117 Cal. App.2d 50, 56 [255 P.2d 70].) (21) While there are certain differences between an agent and an employee, both are workers for another under an express or implied employment; one may be *542 both an agent and an employee. (Gipson v. Davis Realty Co. (1963) 215 Cal. App.2d 190, 205 [30 Cal. Rptr. 253]; Ingle v. Bay Cities Transit Co. (1945) 72 Cal. App.2d 283, 286 [164 P.2d 508].)

III
Much of plaintiff's opening brief is devoted to the argument that the trial court improperly sustained defendant's evidentiary objections to plaintiff's declaration in opposition to the motion for summary judgment. It is unnecessary to consider this contention for the following reasons: (1) without regard to the evidentiary showing made by the respective parties, summary judgment was proper because the complaint failed to state a cause of action for imposition of a constructive trust based on the alleged oral contract to make a will; (2) parol evidence was inadmissible to supply the terms lacking in the writing of November 10, 1981, which were necessary in order to make that writing a sufficient memorandum of contract under the statute of frauds; and (3) there was no extrinsic evidence bearing upon interpretation of the writing of October 1981.
Plaintiff also argues that the trial court abused its discretion in granting summary judgment if it did so on the sole ground that plaintiff's opposing papers failed to set forth a separate statement responding to the material facts claimed by defendant to be undisputed. (Code Civ. Proc., § 437c, subd. (b).)[6] The granting of defendant's motion for summary judgment is supported by grounds other than plaintiff's failure to comply with that requirement.

DISPOSITION
The judgment is affirmed.
Thompson, J., and Johnson, J., concurred.
NOTES
[1]  The parties henceforth are referred to as plaintiff and defendant, respectively.
[2]  In addition to the Y.M.C.A., the complaint named as a defendant First Interstate Bank of California in its capacity as executor of the estate of Clara Hollowell, deceased. The first and second causes of action were directed against the bank alone. Those causes of action sought, respectively, damages for decedent's alleged breach of contract by having failed to devise certain real property (938 Second Street, Santa Monica) to plaintiff and pay to her the sums of money included in plaintiff's claim filed in the probate proceeding and rejected by the bank; and the reasonable value of personal services rendered by plaintiff to decedent which were included in the rejected claim.
[3]  Section 1624 was amended to delete the underscored portion of subdivision 6 (Stats. 1983, ch. 842, § 6, operative Jan. 1, 1985) which is superseded by Probate Code section 150.
[4]  Failure of the complaint to state a cause of action for imposition of a constructive trust was not specified by the trial court as a ground for the granting of defendant's motion for summary judgment. However, "[w]e are not confined, in considering the granting of the summary judgment, to the sufficiency of the stated reasons. It is the validity of the ruling which is reviewable and not the reasons therefor." (Barnett v. Delta Lines, Inc. (1982) 137 Cal. App.3d 674, 682 [187 Cal. Rptr. 219].)
[5]  It is undisputed that such document is entirely in plaintiff's handwriting except for the signature of the decedent.
[6]  Code of Civil Procedure section 437c, subdivision (b) provides in pertinent part: "The opposition papers shall include a separate statement which responds to each of the material facts contended by the moving party to be undisputed, indicating whether the opposing party agrees or disagrees that those facts are undisputed. The statement also shall set forth plainly and concisely any other material facts which the opposing party contends are disputed.... Failure to comply with this requirement of a separate statement may constitute a sufficient ground, in the court's discretion, for granting the motion...."
