Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Datatype Conversion Problem

Status
Not open for further replies.

edove

Programmer
Nov 5, 2001
48
GB
My problem is this.
I have a view. The first document in this view contains the last invoice number to be used. Format eg = RUS-0111.
Using StrRight, I extract the number (all to right of "-"). I need to add one to this and then enter the new number into a field.

The problem is that a lot of the numbers, start with a 0, and when I convert to a number in order to add 1, the 0(s) get stripped out. What can I convert it to, which will keep the zeros? I have tried cdl, clng and cint.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top