I have an integer value that needs to be displayed in an error message. Not a big deal, but would love to have "eight" in the message and not 8. Is there a built in function to convert integer values to their string representation?
Printable View
I have an integer value that needs to be displayed in an error message. Not a big deal, but would love to have "eight" in the message and not 8. Is there a built in function to convert integer values to their string representation?
It's in VB, but I am sure you can convert to VB.Net
http://www.ozgrid.com/VBA/ValueToWords.htm
No however google it and someones probably written a function for it. You could also easily write your own, depending on how high the number could be.
Your point?Quote:
VB is VB.Net. VB 6 is not.
You said he may have to convert it to VB.Net, I'm letting him no that no conversion is necessary because they are the same thing.
this might give you a head start if you're writing your own function.
Currency to Words
Divide the number a few Times: One Trillion, One Trillion, One Trillion.. etc heh.
:afrog:
I have just written such function . I think you can do yourselft.
it is not difficult.
you have to skill about string function and you can use select case clause for that function.