troubleshooting Question

Format dbRow

Avatar of Larry Brister
Larry BristerFlag for United States of America asked on
.NET ProgrammingASP.NETMicrosoft Development
2 Comments1 Solution201 ViewsLast Modified:
The data below returns a nVarchar as string and may or may not have a decimal and trailing zeros.

Example
2000
2000.25
200.5

I need to format this so that a comma is added and IF there's decimal, then the decimal comes back to 2 decimals

Example
2,000
2,000.25
2,000.50
ASKER CERTIFIED SOLUTION
RameshS

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 2 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros