By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
444,124 Members | 2,054 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 444,124 IT Pros & Developers. It's quick & easy.

Formatting a number

P: n/a
Roy
Hello,
I had posted a few days ago regarding the lpad and rpad and thanks to
help i got I was able to format my data.On the same lines I need help
in formatting negative values.I am able to identify these negative
values and I want to format them.They have to be formatted as follows;

-6.43 should be 0-6.430( 7 digits).or if it -20.3 it should be
-20.300.How would I do this.When I use lpad or rpad or just plain
format, all i am getting is -06.430 or -200.300.

Any suggestions?

Thanks for your help.

Roy
Dec 10 '07 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On Dec 10, 2:25 pm, Roy <praish1...@yahoo.comwrote:
Hello,
I had posted a few days ago regarding the lpad and rpad and thanks to
help i got I was able to format my data.On the same lines I need help
in formatting negative values.I am able to identify these negative
values and I want to format them.They have to be formatted as follows;

-6.43 should be 0-6.430( 7 digits).or if it -20.3 it should be
-20.300.How would I do this.When I use lpad or rpad or just plain
format, all i am getting is -06.430 or -200.300.

Any suggestions?
Suggestion 1. Write your questions more carefully.
Suggestion 2. Try the answers given to you previously. Remember
Format(-6.23, "000.000")?
Suggestion 3. Stop with the lpad and rpad stuff or find a newsgroup
for some application that uses lpad and rpad.
Suggestion 4. Experiment a bit. Believe it or not, God does not reveal
VBA answers in a dream, or even on stone tablets. Try things and
suddenly "Oh, that works!". There is no truth to the rumour that you
will go blind if you fool around with VBA too much.

To some up, give the people you're asking for help a break.
Dec 11 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.