@raprap,
Huh? This seems to be based on all 7-digit numbers - not the specific 7-digit numbers in the problem which don't contain the digits 0, 8, and 9 - and it doesn't make sense. 1/7th (give or take 1) of all N-digit numbers are divisible by 7. More generally, 1/7th (give or take 1) of any group of consecutive integers are divisible by 7.
Note that this fact doesn't get us closer to a solution. Is this for a programming class? If so, it's a trivial program to write. If not, I'm not sure how you'd reason out a solution.