I usually doorCode:right("0000000000" & [fieldname], x)
, x being string length.Code:left([fieldname] & "00000000000", x)
right("0000000000" & cstr([fieldname]),10)
The String() function is the equivalent of the Replication() function, so I was just expressing that point. From the help files, String() - Returns a Variant (String) containing a repeating character string of the length specified. From msdn, Replicate() - Returns a character string that contains a specified character expression repeated a specified number of times. Your function isn't quite the same.Didn't know about that one either - does it do the same as my reply?
try
format([FieldName],"0000000.00")
It cannot change the Format() condition, it is probably changing the result when viewed in Datasheet.
It cannot change the Format() condition, it is probably changing the result when viewed in Datasheet.
Is this a Currency data type? Did you apply a format in the Format property of that field? Also, write down some examples of what some records are like BEFORE and AFTER.
Quite interesting GalaxiomAtHome. I would imagine that things can get changed in the VBA editor but in a query it should throw a syntax error. Anything put in quotes should remain as it was typed in a query (especially if it wasn't put in the Criteria row).After seeing what can happen to functions in the Greek variant of Access I would't rule out any possibility.
I think what irade92 is after is a dynamic way of padding, so something like this:
Code:String(10 - Len("String"), "0")