a made something similar the other week, as andy mentions, you'll get clicks if you arbitrarily jump from different parts of a sample, but this can be avoided by hanning window/ block overlap.
my patch is a simple timestretcher for audio files, but i think it could be easily modified to do delaylines too.