Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8294637
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T14:17:19+00:00 2026-06-08T14:17:19+00:00

I am new in creating reports using crystal reports and c#. I created a

  • 0

I am new in creating reports using crystal reports and c#. I created a c# program which displays clients’ allowance.My only problem for now is that a field is not displaying what I wanted. I have a table in my sql that has a ‘varchar’ data type because I want it to display a number with a text. My problem is that it doesn’t put a comma when a value has a thousand separator. What I want is to display my value as 25,000/day instead of 25000/day. Is it possible to to this? What data type should I use?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T14:17:25+00:00Added an answer on June 8, 2026 at 2:17 pm

    There is no data type supporting your requirement in SQL Server.

    A better approach would be to use decimal for your numbers and a separate column for your text part i.e. /day. This will help you run queries requiring averages, minimum, maximum on the decimal field. Later you can format it in C# for your reports.

    But if you can’t change the database then you may split the string in c# based on character “/” and then you may use ToString() for formatting the number with commas. Something on the following lines:

        string str = "25000/day";
        string[] tempArray = str.Split('/');
        double number = 0;
        if(double.TryParse(tempArray[0],out number))
        {
            Console.WriteLine("Invalid Number");
        }
        Console.WriteLine(number.ToString("###,###.#######") + "/" + tempArray[1]);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have problem creating new instance of excel 2007 using VBA (from Access 2002).
I am new to Crystal Reports v10 and I'm creating reports to embed in
I'm creating new Site Definitions using this method: http://weblogs.asp.net/paulballard/archive/2007/04/09/creating-a-custom-sharepoint-2007-portal-site-definition-using-the-portalprovisioningprovider-class.aspx and when they get created,
I'm new to creating installers using Visual Studio, and was wondering about the Global
Often I'm creating reports in Visual Studio's Crystal Reports and want to have a
I am new in creating Report System using Visual Stuido 2010 C#. I already
I am creating a web front end for clients to download their reports. The
I have created a C++/CLI mixed DLL which I am using from C# Winforms
I'm building a C# application that runs/exports batches of Crystal Reports to PDF files.
I have a project using ASP.Net MVC 3 and now I'm creating a report

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.