Visvamitra Muni controlled the senses by yogic trance, but when he happened to meet Menaka (a heavenly society woman), he became a victim of sex, and the artificial way of controlling the senses failed
SB Canto 1
Here is the same Supreme Personality of Godhead whose transcendental form is experienced by the great devotees who are completely cleansed of material consciousness by dint of rigid devotional service and full control of life and the senses. And that is the only way to purify existence.
As it is stated in Bhagavad-gītā, the Lord can be known in His real nature by dint of pure devotional service only. So it is stated here that only the great devotees of the Lord who are able to clear the mind of all material dust by rigid devotional service can experience the Lord as He is. Jitendriya means one who has full control over the senses. The senses are active parts of the body, and their activities cannot be stopped. The artificial means of the yogic processes to make the senses inactive has proved to be abject failure, even in the case of great yogīs like Viśvāmitra Muni. Viśvāmitra Muni controlled the senses by yogic trance, but when he happened to meet Menakā (a heavenly society woman), he became a victim of sex, and the artificial way of controlling the senses failed. But in the case of a pure devotee, the senses are not at all artificially stopped from doing anything, but they are given different good engagements. When the senses are engaged in more attractive activities, there is no chance of their being attracted by any inferior engagements. In the Bhagavad-gītā it is said that the senses can be controlled only by better engagements. Devotional service necessitates purifying the senses or engaging them in the activities of devotional service. Devotional service is not inaction. Anything done in the service of the Lord becomes at once purified of its material nature. The material conception is due to ignorance only. There is nothing beyond Vāsudeva. The Vāsudeva conception gradually develops in the heart of the learned after a prolonged acceleration of the receptive organs. But the process ends in the knowledge of accepting Vāsudeva as all in all. In the case of devotional service, this very same method is accepted from the very beginning, and by the grace of the Lord all factual knowledge becomes revealed in the heart of a devotee due to dictation by the Lord from within. Therefore controlling the senses by devotional service is the only and easiest means.