BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Formatting Floats

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Internet Isapi-WebBroker
View previous topic :: View next topic  
Author Message
Del Murray
Guest





PostPosted: Mon May 14, 2007 6:05 pm    Post subject: Formatting Floats Reply with quote



Does anyone have a source for a good number formatting routine ??

When formating currency for html output, "formatfloat" wont allow you to
right justify the output so that currency fields line up with other currency
fields above them. I have never found where it allowed a "suppressed zero"
place holder in the output. I guess I could write one real quick but thought
maybe someone has a few lines of code to toss my way.

TIA
Del
Back to top
Richard Bakos
Guest





PostPosted: Mon May 14, 2007 7:57 pm    Post subject: Re: Formatting Floats Reply with quote



Del Murray wrote:

Hi Del,

Quote:
When formating currency for html output, "formatfloat" wont allow you to
right justify the output so that currency fields line up with other currency
fields above them. I have never found where it allowed a "suppressed zero"
place holder in the output. I guess I could write one real quick but thought
maybe someone has a few lines of code to toss my way.

Can you wrap the output in a <div> and float that right in the
container? Also, the <td> tag does have the align attribute.

- Rich Bakos
Back to top
Del Murray
Guest





PostPosted: Mon May 14, 2007 8:23 pm    Post subject: Re: Formatting Floats Reply with quote



Rich,

Yea the <td does have align but the <input type=text doesn't have an align .
If you have a stack of text boxes and different size amounts , it looks like
crap because everything keeps coming out left justified unless you force
blanks onto the front of the small numbers so that they push to the right
and the decimal places all line up .

I'm a neat-freak I guess

Del
Back to top
Richard Bakos
Guest





PostPosted: Mon May 14, 2007 10:49 pm    Post subject: Re: Formatting Floats Reply with quote

Del Murray wrote:

Quote:
Yea the <td does have align but the <input type=text doesn't have an align .
If you have a stack of text boxes and different size amounts , it looks like
crap because everything keeps coming out left justified unless you force
blanks onto the front of the small numbers so that they push to the right
and the decimal places all line up .

You can cheat it with a style -

<input type="text"; size="25"; style="Text-Align: Right;">

Rich
Back to top
Del Murray
Guest





PostPosted: Mon May 14, 2007 11:19 pm    Post subject: Re: Formatting Floats Reply with quote

Darn, .. I knew that ... it was filed in the back of the back drawer in the
back of my head ...

I gotta get a vacation'

Thanks Rich
Back to top
Richard Bakos
Guest





PostPosted: Tue May 15, 2007 12:23 am    Post subject: Re: Formatting Floats Reply with quote

Del Murray wrote:

Quote:
Darn, .. I knew that ... it was filed in the back of the back drawer in the
back of my head ...

Lol! I had to go look at some of our source to see how we did it...
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Internet Isapi-WebBroker All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.