Darkhouse Lane in Coseley was cordoned off after the incident on Wednesday night, with parents of children at nearby Rosewood School told to keep their children at home due to the school being closed for the day.
A police van blocked the entrance to Darkhouse Lane in Coseley, with the road closed at the Siddons Road junction down to Darkhouse Baptist Church.
West Midlands Ambulance Service said a seriously injured man in his 20s had been found in the road late on Wednesday night.
A spokeswoman for West Midlands Ambulance Service said: "We were called at 11.17pm to the junction of Webb Street and Darkhouse Lane, Coseley. An ambulance, two paramedic officers and a MERIT trauma doctor attended.
"A man, who had sustained a serious injury, was given trauma care by the team of ambulance staff on scene before being conveyed on blue lights to hospital for further care."
A police presence remained in place throughout Thursday as officers at the scene conducted forensic examination, causing disruption for rail travellers heading towards Coseley station and Rosewood School.
A spokeswoman for West Midlands Police said: "We were called by ambulance colleagues to Darkhouse Lane, Coseley, after a man suffered gunshot injuries to his leg at 11.30pm yesterday.
"The man, who is in his 20s, was taken to hospital with serious injuries, where he remains today.
"A scene was held while we conducted forensic examination and we are reviewing CCTV to determine exactly what happened.
"If you have any information, please contact us via Live Chat on our website or by calling 101. Please quote log number 4374 of May 25."
David Kirk, headteacher at Rosewood School, said: "There was a police incident on neighbouring Darkhouse Lane overnight which prevented access to the school this morning.
"We took the decision very early to close the school and let parents know first thing.
"We will be re-opening as normal tomorrow."