I have a number field that needs to be a text field in order to combine them to narrow down the unique values.
THe first set of numbers should always be three digits, and if they are a one or two-digit number, zeros should be displayed. (005, 010, 050, 100, 110, etc).
I have set ALL of my formats in the tables, forms, queries and reports, where this first 3-digit number appears to be 000. But when I do the concantanation to combine the numbers, the leading zeros are lost.
Here's the code:
Private Sub LE_1_LostFocus()
Me.LE_Acct_1 = Me.LE_1 & "-" & "135" & Me.LE_2
Me.LE_Acct_2 = Me.LE_2 & "-" & "135" & Me.LE_1
End Sub
Me.LE_1 = 045
Me.LE_2 = 130
What I should get: What I'm getting:
Me.LE_Acct_1 = 045-135130 45-135130
Me.LE_Acct_2 = 130-135045 130-13545
I've tried doing formatting within the code and it still doesn't work. Any suggestions?
Thanks,
Carie
THe first set of numbers should always be three digits, and if they are a one or two-digit number, zeros should be displayed. (005, 010, 050, 100, 110, etc).
I have set ALL of my formats in the tables, forms, queries and reports, where this first 3-digit number appears to be 000. But when I do the concantanation to combine the numbers, the leading zeros are lost.
Here's the code:
Private Sub LE_1_LostFocus()
Me.LE_Acct_1 = Me.LE_1 & "-" & "135" & Me.LE_2
Me.LE_Acct_2 = Me.LE_2 & "-" & "135" & Me.LE_1
End Sub
Me.LE_1 = 045
Me.LE_2 = 130
What I should get: What I'm getting:
Me.LE_Acct_1 = 045-135130 45-135130
Me.LE_Acct_2 = 130-135045 130-13545
I've tried doing formatting within the code and it still doesn't work. Any suggestions?
Thanks,
Carie