
435 S.E.2d 382 (1993)
CITY OF VIRGINIA BEACH
v.
BOARD OF SUPERVISORS OF MECKLENBURG COUNTY, et al.
Record No. 921204.
Supreme Court of Virginia.
September 17, 1993.
M. Scott Hart, Richmond (John F. Kay, Jr., George A. Somerville, Samuel M. Brock, III, Richmond, Leslie L. Lilley, City *383 Atty., William M. Macali, Sr. Asst. City Atty., Virginia Beach, Mays & Valentine, Richmond, on briefs), for appellant.
Patrick M. McSweeney, Richmond (William T. Fitzhugh, McSweeney, Burtch & Crump, on brief), for appellees.
William W. Bennett, Jr., Halifax (Bennett and Rand, on brief), for appellee Bd. of Sup'rs of Halifax County.
(Russell O. Slayton, Slayton, Bain and Clary, Lawrenceville, on brief), for appellee Bd. of Sup'rs of Mecklenburg County.
Present: All the Justices.
WHITING, Justice.
In this case involving a proposed water supply system for the City of Virginia Beach, we decide whether Code § 15.1-875 requires county consent before the City may exercise its contractual right to use water stored in a reservoir located partially in Mecklenburg and Halifax Counties.
Code § 15.1-875 provides in pertinent part:
A municipal corporation may provide and operate within or without the municipal corporation water supplies and water production, preparation, distribution and transmission systems, facilities and appurtenances for the purpose of furnishing water for the use of the inhabitants of the municipality [and] may contract with others for such purposes and services....
No municipal corporation, after July 1, 1976, shall construct, provide or operate without the boundaries of such municipal corporation any water supply system prior to obtaining the consent of the county or municipality in which [the] system is to be located; provided, however, no consent shall be required for the operation of any such water supply system in existence on July 1, 1976.
In the early 1980s, the City of Virginia Beach (the City) decided to secure water for its water system by withdrawing it from Pea Hill Creek, a tributary of Lake Gaston, which is a water impoundment facility on the Roanoke River. The City planned to transport the water by pipe lines approximately 86 miles through a number of Virginia counties and municipalities, all of which gave the consent required by Code § 15.1-875.
However, the City needed assurance of a sufficient water flow in Pea Hill Creek to supply water during periods of dry weather. Accordingly, in 1984, it contracted with the United States Government (the Government) for the right to use a designated amount of the water stored in the John H. Kerr Reservoir, which is located partially in Mecklenburg and Halifax Counties. The reservoir, owned and operated by the Government since 1953, was part of its John H. Kerr Dam project, designed and built to contain water from the Roanoke River for flood control, recreational, water-supply, and hydropower purposes.
Following are the pertinent provisions of the City's contract: "The Government shall operate and maintain" the dam and reservoir; the City has "the right to utilize an undivided 1.066 percent ... of the usable storage space in the [reservoir]" by requiring the Government to release sufficient water from the City's share of stored reservoir water to maintain the required water level in Pea Hill Creek.[1]
The City did not seek the prior consent of Mecklenburg and Halifax Counties (the Counties) to its use of the water in the reservoir because the City did not believe its contractual right to that water was subject to the consent requirement of Code § 15.1-875. The Board of Supervisors of Mecklenburg County (Mecklenburg) disagreed with this interpretation of Code § 15.1-875 and filed this action against the City. The Board of Supervisors of Halifax County (Halifax) later intervened in that *384 action.[2] Both Counties sought a declaratory judgment that Code § 15.1-875 required their consent to the City's exercise of its contractual right.
After the pleadings were filed and some pretrial proceedings completed, the City and Mecklenburg each moved for summary judgment consistent with its construction of Code § 15.1-875. Upon a consideration of admissions in the pleadings and pretrial proceedings, and after hearing argument of counsel, the trial court agreed with Mecklenburg's construction of Code § 15.1-875 and entered summary judgment, declaring that this code section required the City to obtain the Counties' consent "before [it] may operate that portion of its water supply system which involves water storage in the [reservoir]." The City appeals, and the Counties assign cross-error.
Because the parties recognize correctly that Code § 15.1-875 is ambiguous, we resort to principles of statutory construction. Virginia Dep't of Labor & Indus. v. Westmoreland Coal Co., 233 Va. 97, 101-102, 353 S.E.2d 758, 762 (1987). In doing so, our primary objective is to determine the legislative intent in the use of the term in question. Harward v. Commonwealth, 229 Va. 363, 365, 330 S.E.2d 89, 90 (1985).
An important principle of statutory construction is that "[w]ords in a statute are to be construed according to their ordinary meaning, given the context in which they are used." Grant v. Commonwealth, 223 Va. 680, 684, 292 S.E.2d 348, 350 (1982). The context may be examined by considering the other language used in the statute, VEPCO v. Board of County Supervisors, 226 Va. 382, 387-88, 309 S.E.2d 308, 311 (1983), and the language of other statutes dealing with closely related subjects. See Commonwealth v. Appalachian Elec. Power Co., 193 Va. 37, 44, 68 S.E.2d 122, 126 (1951) (similar tax on another class of public service corporations similarly situated examined because it provided plain expression of legislative intent).
Examining the statutory scheme involving municipally run water systems, we see: (1) the authorization in Code § 15.1-875 to municipalities to "provide and operate... water production, preparation, distribution and transmission systems, facilities and appurtenances" with a proviso that no municipality "shall construct, provide or operate" such systems after July 1, 1976, without prior approval of any county or municipality in which that system "is to be located," and (2) the language of a closely related statute, Code § 15.1-335, which authorizes cities and counties to acquire an existing "waterworks system," but contains no provision for the consent of another jurisdiction in which such a system is located.
In our opinion, these statutory provisions evidence a legislative intent to impose the consent requirement upon a Virginia municipality's construction, provision, or operation of those tangible parts of a water supply system that are to be built in another Virginia jurisdiction after July 1, 1976. The reservoir in question was built before that date, and the summary judgment proceedings indicate that the Government's change in the allocation of a part of the storage capacity of the reservoir did not involve the City in its construction, provision, or operation. We conclude, therefore, that the City's contractual right to use water in the reservoir as a part of its water supply system did not require consent under Code § 15.1-875. Accordingly, the trial court erred in entering a summary judgment declaring that such consent was required.
In an assignment of cross-error, the Counties contend that the trial court erred *385 in ruling upon the City's motion for summary judgment before it ruled upon Mecklenburg's motion to compel the City to answer the Counties' discovery requests.[3] The Counties argue that if the City had been required to answer their discovery requests before the trial court ruled on the motions for summary judgment, such answers may have established: (1) that a part of the physical facilities of the City's water supply system would be located within the Counties, and (2) that the City "considered" its storage rights as part of its water supply system.
Although Mecklenburg asserted these arguments in its motion to stay or to strike the City's motion for summary judgment, the arguments were waived when the motions for summary judgment were argued. At that time, the Counties agreed that both parties' motions could be heard and decided at the same time.[4] Hence, we will not consider this assignment of cross-error. Rule 5:25.
Accordingly, we will reverse the judgment of the trial court and will enter a declaratory judgment in favor of the City in conformity with this opinion.
Reversed and final judgment.
COMPTON, J., concurs in the result.
NOTES
[1]  The extent of the City's right to require the release of water was later reduced by the Government's modification of the City's permit to take water from Pea Hill Creek. This modification does not affect the issues in this case.
[2]  Halifax filed no pleadings or motions in the trial court other than its motion for leave to intervene and its "petition in intervention."
[3]  Because our decision is based solely upon a construction of Code § 15.1-875, we need not consider the Counties' other assignment of cross-error regarding the City's allegedly untimely assertion of a defense under Code § 15.1-1250.1.
[4]  The Counties did not object to the trial court's acceptance of the City's assurance that none of the physical facilities of its water supply system would be located in the Counties. Their only reservation to the court's disposition of the case on the motions for summary judgment was that if the City withdrew from its "concession that the storage space is part of their system ... we will need to revisit the motion to compel." The City has not withdrawn from its "concession" that its contractual right to a part of the stored water was a part of its proposed water supply system.
