Welcome Guest ( Log In | Register)



 
Reply to this topicStart new topic
> [tutorial] Visual Basic 6, Adding Commas to Large Numbers
zachtk8702
post Feb 10 2005, 03:26 AM
Post #1


Member [Level 2]
*****

Group: Members
Posts: 81
Joined: 3-August 04
Member No.: 609



This isn't a very long tutorial. I get asked this often, so here is the solution. The following code will return a string containing a number that has commas appropriately placed:

Code:

myStringOrProperty = FormatNumber(3587532789053, 0)


The second parameter (0) represents how many decimal places you want the returned number to go out to. Unless your number contains its own decimal, you probably don't want .00 at the end of every number you have.

The above code would return:
3,587,532,789,053

This should make life easier for many...
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. [tutorial] Visual Basic 6(1)
  2. Parking Domains(3)
  3. Simple Login In Visual Basic 6(5)
  4. How To Edit Your "index Page"(0)
  5. Making Winrar Archives(11)
  6. Adding Ur Own Files On Send To(0)
  7. Bit Shifting In Vb(0)
  8. How To Make A Web Browser(47)
  9. Custom Bbcode Tags In Smf(0)
  10. Creating A Simple Image Viewer(3)
  11. Creating A Timer Program(8)
  12. How To Install An Openoffice Dictionary Manually(3)
  13. Adding Data To A Database And Displaying It Later(1)
  14. Adding Your Website To Google(19)
  15. Adding An Aef Forum To Snews Cms(2)
  1. Ftp In Visual Basic 6.0(0)


 



- Lo-Fi Version Time is now: 16th May 2008 - 06:11 PM