Hadithcore
Al-Adab Al-Mufrad, 661

Sahl ibn Sa'd said, "There are two hours in which the gates of heaven are opened. At those times very rarely is the supplication of someone who makes supplication rejected:

when the call to prayer has been given and when in battle ranks in the Cause of Allah."

حَدَّثَنَا إِسْمَاعِيلُ قَالَ‏:‏ حَدَّثَنِي مَالِكٌ، عَنْ أَبِي حَازِمٍ، عَنْ سَهْلِ بْنِ سَعْدٍ قَالَ‏:‏ سَاعَتَانِ تُفْتَحُ لَهُمَا أَبْوَابُ السَّمَاءِ، وَقَلَّ دَاعٍ تُرَدُّ عَلَيْهِ دَعْوَتُهُ‏:‏ حِينَ يَحْضُرُ النِّدَاءُ، وَالصَّفُّ فِي سَبِيلِ اللهِ‏.‏

References2 variants
In-Book Reference
Book 31, Hadith 58
English Reference
Book 31, Hadith 661