
709 N.E.2d 747 (1999)
Darlene Wanda MEARS, et al., Appellants-Cross-Defendants,
v.
LAKE COUNTY COUNCIL, et al, Appellees-Cross-Plaintiffs.
No. 64A03-9807-CV-300
Court of Appeals of Indiana.
April 27, 1999.
*748 Jeffrey A. Modisett, Attorney General of Indiana, Sarah E. Scherrer, Deputy Attorney General, Indianapolis, Indiana, Attorney for Appellant.
Gerald M. Bishop, Merrillville, Indiana, Attorney for Lake County Council, Lenore L. Heaphey, James B. Meyer, Meyer, Lyles & Godshalk, P.C., Gary, Indiana, Attorneys for Lake County Commissioners, Attorney for Appellee.

OPINION
STATON, Judge.
The State of Indiana appeals the denial of its motion to dismiss a cross-claim by Lake County for indemnification of legal expenses. The State raises one issue for our review, which we restate as: whether the trial court erred in denying the State's motion to dismiss.
We reverse.
The Lake County Council and Lake County Commissioners (collectively, "the County"), along with the Lake County Juvenile Court, Darlene Wanda Mears and two employees of the Lake County Juvenile Detention Center ("Employees"), were named as defendants in an action brought by John, Debra and Michael Swanson (collectively, "the Swansons").[1] The County filed a crossclaim against the State and Judge Mears, seeking indemnification for any legal expenses incurred in defending the Employees and any judgment that might result. The State moved to dismiss the cross-claim. The trial court denied the motion to dismiss, and this appeal ensued.
The State contends that the trial court erred by not granting its motion to dismiss the County's cross-claim for failure to state a claim upon which relief can be granted. We first address whether the motion was properly treated as a motion to dismiss under Ind. Trial Rule 12(B)(6), or whether it should have been considered as a motion for summary judgment under Ind. Trial Rule 56(C). T.R. 12(B) states:
If, on a [12(B)(6) motion], matters outside the pleading are presented to and not excluded by the trial court, the motion shall be treated as one for summary judgment and disposed of as provided in Rule 56. In such case, all parties shall be given reasonable opportunity to present all material made pertinent to such a motion by Rule 56.
In the State's motion to dismiss, and in the County's response to that motion, the parties submitted materials outside of the pleadings, including an affidavit and a portion of a deposition. It is clear from the order denying the State's motion to dismiss that these extraneous materials were considered by the trial court. Therefore, pursuant to Ind. Trial Rule 12(B), the State's motion to dismiss should have been treated as a motion for summary judgment. Dixon v. Siwy, 661 N.E.2d 600, 603 (Ind.Ct.App.1996).[2] We will treat the appeal as if it comes from the denial of summary judgment. Id. at 605.
When reviewing the grant or denial of summary judgment, we use the same standard *749 used by the trial court. Ramon v. Glenroy Construction Co., Inc., 609 N.E.2d 1123, 1127 (Ind.Ct.App.1993), trans. denied. Summary judgment is appropriate only when the evidentiary matter designated by the parties shows that there is no genuine issue as to any material fact and that the moving party is entitled to a judgment as a matter of law. Id.; Ind. Trial Rule 56(C). The movant bears the burden of establishing the propriety of summary judgment, and all facts and inferences to be drawn therefrom are viewed in a light most favorable to the non-movant. Ramon, 609 N.E.2d at 1127.
The State contends that the trial court erred by not granting the State's motion for summary judgment on the County's cross-claim for indemnification. Specifically, the State argues that the statute providing for the establishment of juvenile detention facilities requires that the county pay all expenses of those facilities, including legal expenses. IND.CODE § 31-6-9-5(b) (Supp. 1996).[3] IC 31-6-9-5(b) provides, "If these [juvenile detention] facilities are operated by the juvenile court, the judge shall appoint staff and determine the budgets. The court may contract with other agencies to provide these facilities. All expenses shall be paid by the county." The term "expenses" is not defined in the statute, and the County argues that the statute does not include legal expenses. However, we must ascertain and implement the legislature's intent by giving effect to the ordinary and plain meaning of the language used in the statute. Clifft v. Indiana Dept. of State Revenue, 660 N.E.2d 310, 316 (Ind.1995).
The plain language of IC 31-6-9-5(b) reveals that the County is required to pay all expenses of the juvenile detention facility. BLACK'S LAW DICTIONARY 577 (6th ed.1990) defines "expense" as: "That which is expended, laid out or consumed. An outlay; charge; cost; price. The expenditure of money, time, labor, resources, and thought. That which is expended in order to secure benefit or bring about a result." Legal costs and judgments are part of the "price" that must be paid in order to derive the "benefit" of having a juvenile detention center. Accordingly, legal costs and judgments would fall into the definition of expenses. Therefore, we believe that the "expenses" provided for in IC 31-6-9-5(b) include legal costs incurred in defending the Employees, and the payment of any judgment that might be entered against the Employees. Because the County is statutorily obligated to pay the legal expenses of the juvenile detention facility, the trial court erred by refusing to grant summary judgment for the State on the County's cross-claim for indemnification.
Despite the plain language of IC 31-6-9-5(b), the County argues that the State is responsible for paying the legal expenses of the Employees. The County contends that Judge Mears had exclusive control of the Employees, and should be held liable for the Employees' actions under the doctrine of respondeat superior. The argument follows that, under IND.CODE § 33-13-17-2 (1993), the State is liable for the costs incurred in defending Judge Mears, and the payment of any judgment entered against her. In support of its claim for indemnification, the County relies on Delk v. Board of Commissioners of Delaware County, 503 N.E.2d 436 (Ind.Ct.App.1987). In Delk, this court held that the county could not be held liable for the acts of the sheriff's deputies. This court held that because the deputies were under the exclusive control of the sheriff, who was an agent of the State, there was no agency relationship between the county and the deputies, and the county could not be held liable for the deputies' actions. Id. at 440.
The County's reliance on Delk is misplaced. While an analogy can be drawn between Delk and the present case as it relates to respondeat superior and liability issues, Delk does not stand for the proposition that the State must pay the costs of defending the Employees. Further, even if the trial court finds that the County is not liable for the actions of the Employees under respondeat superior, Judge Mears cannot be held liable. *750 Judge Mears has already been granted summary judgment and dismissed from this action. See Swanson, 671 N.E.2d at 435, 438. Therefore, no judgment can be entered against her for which the State will be liable. Moreover, the statute does not provide that the State must pay the expenses incurred in defending all persons under the judge's control. Therefore, there is no basis on which the State can be held to indemnify the County for the costs of defending the Employees of the juvenile detention facility. We reverse and remand with instructions to enter summary judgment for the State on the County's cross-claim for indemnification.
Reversed and remanded.
BAILEY, J., and FRIEDLANDER, J., concur.
NOTES
[1]  The Lake County Juvenile Court and Darlene Wanda Mears, who was the juvenile court judge at the time of the underlying incident, have been dismissed from the suit. Lake County Juv. Ct. v. Swanson, 671 N.E.2d 429 (Ind.Ct.App.1996), trans. denied.
[2]  Although the trial court erred in failing to treat the State's motion to dismiss as a motion for summary judgment, we hold that the error committed by the trial court was harmless. Both parties were given the opportunity to, and did, present materials outside of the pleadings to the court. See Dixon, 661 N.E.2d at 604.
[3]  This statute has been recodified at IND.CODE § 31-31-8-3 (1998). However, we will refer to the statute in effect at the time this action arose.
