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 7490259
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T15:34:21+00:00 2026-05-29T15:34:21+00:00

I am adding the Procs class as a List item: public static List<Procs> allprocs

  • 0

I am adding the “Procs” class as a List item:

public static List<Procs> allprocs = new List<Procs>();

So when a user fills out a form and clicks “Add Proceedure”:

private void btAddProcedure_Click(object sender, EventArgs e)
{
    ClaimVars.allprocs.Add(new Procs
    {

        TreatmentBusinessID = Convert.ToInt32(proLocID.Text),
        DiagCodeID = ClaimVars.DiagID,
        CPTCodeID = ClaimVars.CPTID,
        Charges = Convert.ToDouble(txtCharges.Text),
        AmountPaid = Convert.ToDouble(txtPaid.Text),
        DateServicedFrom = Convert.ToDateTime(dateTimePicker1.Text),
        DateServicedToo = Convert.ToDateTime(dateTimePicker2.Text),
        Notes = notesDiagServ.Text
    });

    // Change the DataSource.
    listBox1.DataSource = null;
    listBox1.DataSource = ClaimVars.allprocs;
    }
}

They will see a new list item.

How do I display the values of this class rather than adding the name of the object?

After adding a proceedures, this is how my listbox looks:

Project_LB223.ClaimForms.Procs
Project_LB223.ClaimForms.Procs
Project_LB223.ClaimForms.Procs
Project_LB223.ClaimForms.Procs

This is how I would like it to look:

1     32     44     33.44     22.17     12/17/09 11:21:52     12/22/09 10:31:64     patient was feeling sick.
2     42     72     12.45     10.67     12/18/09 22:51:22     12/23/09 11:21:25     patient was showing signs of fatigue and shortness of breath.
1     68     57     83.64     55.47     12/19/09 23:25:45     12/24/09 15:38:42     the patient is feeling better.
5     12     22     37.44     23.45     12/22/09 16:81:11     12/25/09 19:35:22     the patient does not have any more symptoms.
  • 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-05-29T15:34:22+00:00Added an answer on May 29, 2026 at 3:34 pm

    You can, for example, add ToString() method override, like this:

    public class Procs
    {
        public override string ToString()
        {
           string spaceinbetween = new string(' ', 5);
           return TreatmentBusinessID + spaceinbetween + DiagCodeID + spaceinbetween ...
        }
    }
    

    Hope this helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm refactoring a class and adding a new dependency to it. The class is
Adding an element to the head of an alist (Associative list) is simple enough:
Adding functionality to a class can be done by adding a method or by
When adding new properties to classes, I find myself typing the same things over
I have the following model entity: public class ScheduledTask { public virtual int ScheduledTaskId
I'm new to both JSF and Spring Framework and I'm trying to figure out
I'm adding security to my spring-ws app. i have configured: <sws:interceptors> <bean class=org.springframework.ws.soap.security.xwss.XwsSecurityInterceptor> <property
When adding user input to a web page, it should (unless it's HTML of
Adding source files more than one directory away (e.g. ../../source.cpp or ../../../somewhere_else/source.cpp, vs. just
Adding more than one child to a WPF StatusBar results in poor layout with

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.