Co znamená "nejde"? Musíš se vyjadřovat přesně.
Pokud chceš smazat začátek stringu, tak použij něco takového:
cesta = cesta.substring(start); 
 

