if you want mel:
float $start = 0.0;
float $end = 100.0;
timeControl -e -beginScrub $start -endScrub $end $gPlayBackSlider;
from there you can capture your own start and end values in w/e way you wanna do it.
$gPlayBackSlider is the global string variable for maya's default timeSlider.