A 24-year-old man has been charged with attempted murder in connection with a shooting at a party early Sunday in the Lake View neighborhood on the North Side.

James Warren, of the Gresham neighborhood, is facing felony charges of attempted first degree murder and aggravated battery/discharge of a firearm, Chicago Police announced Monday.

Warren had been at a party in the 2900 block of North Sheffield, but was asked to leave, police said. He returned with a gun at 1:14 a.m. and fired shots, hitting a 21-year-old man in the knees.

The 21-year-old was taken to Illinois Masonic Medical Center, where his condition was stabilized, police said. Warren was taken into custody early Sunday.

Warren’s bail was set at $800,000 at a court appearance on Monday, according to the Cook County sheriff’s office. He was expected to return to court April 24.