Solved

make sure value of text box appears as currency

Posted on 2011-03-21
4
251 Views
Last Modified: 2012-05-11
I have a textbox ... and when dollar amount is retrieved from the database it comes back like this

4.0000

how would i format the textbox so that it appears like a normal dollar amount:

example:

4.00
0
Comment
Question by:vbnetcoder
  • 2
4 Comments
 
LVL 33

Accepted Solution

by:
jppinto earned 500 total points
ID: 35184762
txtboxAmount.Text = Format(txtboxAmount.Text,"0.00")

0
 
LVL 33

Expert Comment

by:jppinto
ID: 35184770
txtboxAmount.Text = txtboxAmount.ToString("#0.00")
0
 
LVL 11

Expert Comment

by:srikanthreddyn143
ID: 35185237
You can use above statement or in generic txtboxAmount.Text = txtboxAmount.ToString("##.##")
0
 

Author Closing Comment

by:vbnetcoder
ID: 35185584
ty
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

823 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question