Goalkeeper Gilmartin pulled off a string of fine stops at Spotland in a one-sided contest to frustrate Steve Eyre's team and give the Glovers a three-point cushion over their fellow League One strugglers.
Dale were on top during the first half and went within a whisker of scoring when Jean-Louis Akpa Akpro sent a spectacular volley crashing against the crossbar. Akpa Akpro was denied again when he met Nicky Adams' cross at the near post as Gavin Massey blocked his effort on the line.
Yeovil's best opening of the first half was created by on-loan Tottenham winger Jonathan Obika. He raced clear down the left flank and pulled the ball back for Conor Clifford who had time to pick his spot but was unable to beat keeper Matt Edwards from the edge of the area.
Gilmartin dislocated a finger just after the break but played on through the pain barrier to deny Harry Bunn and Akpa Akpro, whose 61st-minute shot he pushed onto a post. The goalkeeper later pushed an Adams' free-kick wide of the upright.
Gilmartin's best save came immediately after Kerrea Gilbert had been sent off for a dreadful challenge on Joe Widdowson in the 77th minute. From the resulting free-kick, Adams' delivery was headed goalwards by Bunn but the keeper brilliantly pushed his effort over the crossbar.