BOSTON (AP) — The effort launched in September to address a shortage of school bus drivers across the state by training members of the Massachusetts National Guard to transport children to and from school has ended, state officials said Monday.

Nearly 240 members of the Guard participated, making almost 15,000 safe pickups and dropoffs and traveling about 300,000 miles during the two-month program, the state Executive Office of Public Safety and Security said in a statement.

With the 13 districts the program served able to hire enough civilian drivers to meet student transportation needs, the Guard was able to end the mission, the statement said.

“By working collaboratively with local districts who requested assistance, the Guard was able to provide critical school transportation support at a time when schools, students and families needed it most,” Gov. Charlie Baker said in a statement.

About 200 Guard members were trained to drive the so-called 7D vehicles, vans designed to carry about 10 passengers. Another 40 provided operational support.

The 13 districts that participated in the program were Brockton, Chelsea, Framingham, Haverhill, Holyoke, Lawrence, Lowell, Lynn, Quincy, Revere, Wachusett Regional, Woburn, and Worcester.