http://code.google.com/p/printf-as3/
var num : int = 500; <http://code.google.com/p/printf-as3/>var str : String = printf('000%d', num); trace(str); //'000500' ------------------------------------------------------- Blog: http://douhua.im Twitter: http://twitter.com/genedna Website: http://douhua.im ------------------------------------------------------- On Tue, Aug 17, 2010 at 10:22 PM, Christophe <christophe_jacque...@yahoo.fr>wrote: > Hello, > > I have an int : 500 > > And I would like to have a string with 0 before. > > String : 000500 > > How to format such a string ? > > Thank you, > Christophe, > > > > ------------------------------------ > > -- > Flexcoders Mailing List > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt > Alternative FAQ location: > https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847 > Search Archives: > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups > Links > > > >