I really like the logic you have used in getting a value with 8 digits, it's great to see people thinking along those lines rather than expecting things to be done with a simple 'out the box' line of code (and thus never really learning how things are actually acheived).
But in instances like this one-liners are the way to go, so hope this helps...
int newNumber = lastReceiptNumber + 1;<br />string displayNumber = newNumber.ToString("D" + receiptDisplayDigits);