Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is this a PADL bug?
Message
From
26/07/2002 09:42:29
 
 
To
26/07/2002 09:21:17
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00682949
Message ID:
00682961
Views:
14
Randy,

n=0
? STR(n)

Doesn't returns "0", returns " 0" ...
So, with ?PADL(STR(n),2,"0") you select only the first two characters (" ")...

Got it ?

To have it working, do it like this:

? PADL(AllTrim(str(n)),2,"0")

[]'s





*--------------------------*
n=0
?STR(n)
Returns "0"


n = 0
?PADL(STR(n),2,"0")
Returns ""
Should this not return "00"?
Juliano Martins Terterola
Microsoft Certified Professional
Porto Alegre - RS - Brazil
9 years of Visual FoxPro experience

"Though we know that time has wings
We're the ones who have to fly..."
Neil Peart - Rush
Previous
Reply
Map
View

Click here to load this message in the networking platform