The accused, Rezaul Karim Ratan, was arrested in Dhaka’s Hazaribagh on Saturday night, according to Sub-Inspector Md Rajib Hasan of the local police station.
Rezaul tried to rape the alleged victim at her home in Madhubazar of Dhanmondi in the capital last Monday night, the police official said, quoting the student.
The woman told police she was injured in the alleged assault when she acted on self-defence.
In June last year, she initiated a case against Rezaul for allegedly beating her up.
Police had been looking for Rezaul since the woman started a case with Dhanmondi police in July last year against Rezaul.
In the second case, she accused him of raping her at different times by promising to marry her when she was studying at Mohammadpur Government College in 2017.
The public administration ministry suspended him after police formally charged him in court in both cases.