can't upload new sketch , old sketch keep running!

hi guys…
I search for this a lot but i dont found any solution so asking you…

I have Arduino Leonardo.Updoaded one sketch for blinking LED.but when I connect arduino to the computer it starts running that code and I cant upload new one!i tried so many times connecting-disconnecting bourd,used reset switch to but it keeps running old code…

please help :blush:

It will keep running the old sketch until you upload a new sketch.