Try
 s:=Copy(IntToStr(100+i),2,2);
Pretty nasty but works well if you know the number range is only going to be
in 0-99
Warren.S

-----Original Message-----
From: Leigh Wanstead [mailto:[EMAIL PROTECTED]
Sent: Monday, 28 July 2003 10:49 a.m.
To: Multiple recipients of list delphi
Subject: [DUG]: Integer conversion


Hello everyone,

I want to convert integer to string. 

Here is the rule

Integer String
1               '01'
2               '02'
3               '03'
4               '04'
5               '05'
6               '06'
11              '11'
12              '12'

It convert int to string, if width less than 1, put '0' in front of String.

I checked help file about format and can not find the right one I want.

TIA

Regards
Leigh

---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"
Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/

#####################################################################################
This e-mail message has been scanned for Viruses and Content and cleared 
by MailMarshal
For more information please visit www.marshalsoftware.com
#####################################################################################
---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"
Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/

Reply via email to