DuPage prosecutors identified the man as Jeffrey H. Beard, 64, of the 1400 block of Avery Avenue.
Beard allegedly entered the woman's residence on Surrey Drive around 10:30 p.m. Saturday, and confronted the woman and her boyfriend, law enforcement officials said. At one point, Beard is alleged to have fired off a round and he also placed the gun against the woman's head, according to prosecutors.
Beard allowed the male guest to leave, and that man contacted the police, who responded and surrounded her residence. The woman was able to run out, prosecutors said. Beard was subdued and hit with a stun gun around 2 a.m. as he tried to flee, according to authorities.
Police said they found a handgun in his possession.
He is charged with felony counts of home invasion and one count of reckless discharge of a firearm, as well as two counts of misdemeanor battery and firearms violations.
"A person's home is their sanctuary where they have every right to feel safe," State's Atty. Robert Berlin said. "It is alleged that Mr. Beard destroyed his victims' sense of security when he decided to arm himself, enter his victim's home and threaten their lives at gunpoint."
Beard's next court appearance is Oct. 2 for arraignment.