|
-
Jul 15th, 2002, 02:12 AM
#1
Thread Starter
New Member
Small Calculation - Urgent help
Please give us the coding to genarate this calculation.
00001,00002,00003..................00009,00010,00011,..........00100
Najath
-
Jul 15th, 2002, 02:16 AM
#2
Re: Small Calculation - Urgent help
Originally posted by Najath
Please give us the coding to genarate this calculation.
00001,00002,00003..................00009,00010,00011,..........00100
Najath
if using SQL server try this
assuming empid is prefix with char E0001.
select replicate('0',(5-len(right(em_id,4)),(cast(right(em_id,4) as numeric)+1) from emp
-
Jul 15th, 2002, 02:43 AM
#3
Hyperactive Member
In VB, you can use Format to make the string have the 5 digits you need, like this:
VB Code:
Private Sub CommandNumbers_Click()
Dim myNum As Integer
For myNum = 1 To 100
Debug.Print Format(myNum, "00000")
Next
End Sub
-
Jul 15th, 2002, 03:59 AM
#4
Thread Starter
New Member
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|