The incident took place when victim Rakesh, wife of a Delhi Jal Board official, was going to her office, 100 metres away from her house, police sources said.
Hearing gunshots, passersby overpowered Sunil and handed him over to the police which later arrested him, said a senior police officer.
The sources said Sunil had been pressurizing Rakesh to have an affair with him but she didn't agree. Sunil and Rakesh belong to Bulandshar.
Sunil told the police that he knew the woman for 15 years but for the last few days, she had not been talking to him due to his "bad" behavior, the officer added.
"We have arrested Sunil and a case has been registered against him at Muradnagar police station", the police officer said.