Use ctrl+home and ctrl+end instead home/end.