[AccessD] more on that Format() to pad text values question

Peterson, Steve Steven.Peterson at qwest.com
Wed Jan 18 14:41:02 CST 2006


Susan,

I may be missing the point entirely, but I usually pad with zero like
this:

Right("000" & YourValue, 3)

YourValue sometimes needs a good trimming first.

Steve

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Susan Harkins
Sent: Wednesday, January 18, 2006 1:08 PM
To: 'Access Developers discussion and problem solving'
Subject: [AccessD] more on that Format() to pad text values question

A small problem that I've notices is that if the string being formatted
is empty or null, Format() returns empty or null, which I understand.
However, is there anyway to force Format() to return something? What if
you need 000 instead of empty or null? I can come up with a function or
expression myself, I'm just wondering if I can use Format() to force the
digits instead? 
 
Susan H. 
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com



More information about the AccessD mailing list