You'll probably have to do it recursively, first creating all options for the first digit, then for each of them, all possible options for the second digit and so on.
Be aware, though, that the number of possible permutations will escalate very quickly. Assuming no "-" in the numbers, it's be something along the lines of NumberOfItems^LengthOfItems. In other words, chances are that the stack will burst like something that bursts violently.
None of this removes duplicates, by the way...