The best expression to choose would depend, as usual, on the context in which it would be used. Anyway, here are a couple of expressions that might help: "You came just when I needed (your) help most." "You came at the right moment; I was in need of help."