[Zope] Formatting a string
Laurie Nason
lnason@bcm.tmc.edu
Tue, 19 Mar 2002 15:15:49 -0600
Hi Sheree,
For your numbers:
Look up zfill useage something like
_.string.zfill(my_string,10) - this fills out leading zeros to 10 characters
For strings I am not sure - there is probably some kind of other parameter
for zfill as to what character you wish to use
hth
Laurie
-----Original Message-----
From: zope-admin@zope.org [mailto:zope-admin@zope.org]On Behalf Of
Beaudette, Sheree
Sent: Tuesday, March 19, 2002 3:03 PM
To: 'ZOPE@ZOPE.ORG'
Subject: [Zope] Formatting a string
Does anyone know of a way to format text such as adding leading zeros or
spacing before or after?
9999 would equal leading zeros to 10 characters = 0000009999
1 Main St would contain spaces up to 20 characters.
Is there anyway to do this in Zope?
_______________________________________________
Zope maillist - Zope@zope.org
http://lists.zope.org/mailman/listinfo/zope
** No cross posts or HTML encoding! **
(Related lists -
http://lists.zope.org/mailman/listinfo/zope-announce
http://lists.zope.org/mailman/listinfo/zope-dev )