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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Form that adds "one" for the next job number

Status
Not open for further replies.

Computethis

IS-IT--Management
Feb 5, 2001
28
0
0
US
I have a form that uses a query to find out the "last job number" in our order log. I know I could simply add "1" to that number HOWEVER - we had a "alpha character" attached to the last number...

Example

Form says: Last number used: [ 7991S ]

Can anyone tell me how to have the form tell them what the "NEW" job number will be without the "alpha character" showing....

I want the form to say:

Next Number to use is [ 7993 ]
And maybe a button to copy that number to the under laying form to the field [Jobnumber]...

Thanks
Mitch
 
Hi,

In your command button on click event assign a textbox on your form the following:
left$([JobNum], len([JobNum])-1))

This will display everything from the left and leave out the last character which would be your alpha character. Of course, this assumes that there will always be one and only one alpha character at the end of the job number.

Have a good one!
BK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top