The 37-year-old woman was making her way home after a night out when she was allegedly attacked between 1.30 and 2.30am on Saturday, February 16.
She was walking close to Dalmuir railway station, near Clydebank, in West Dunbartonshire, when a man approached her and asked if he could walk with her.
A 29-year-old man was arrested and detained in police custody in connection with incident in Glendevon Place.
He was due to appear at Dumbarton Sheriff Court today. Police said a report would be submitted to the procurator fiscal.