Function PadNumber(NumberIn As Long) As String
Dim strNumber As String
strNumber = Format(NumberIn, "000000")
PadNumber = Left(strNumber, 4) & " " & _
Mid(strNumber, 5)
End Function
--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)
"Jeremy Sculler" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> If I have a column with integers:
>
> 12345
> 2345
> 345
>
> .. and want to leftpad the first digits with zeros and insert a space in
> front of the two last digits like this:
>
> 12345 -> 0123 45
> 2345 -> 0023 45
> 345 -> 0003 45
>
> how can that be done in access..?
>
> regards
>
> Jeremy