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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T07:15:16+00:00 2026-06-18T07:15:16+00:00

Basically when I try to move my queries result into a usable format, I

  • 0

Basically when I try to move my queries result into a usable format, I get given outputs such as “systems.collections.whatever”

Instead I want the actual number returned.
this is how I select the value I want

 listBox2.DisplayMemberPath = "MonthlyHourLimit";
            listBox2.ItemsSource = e.Result;
            if (this.listBox2.Items.Count > 0)
                this.listBox2.SelectedIndex = 0;
            limit = listBox2.SelectedItem.ToString();

I should get “156” but instead I get “Timesheet_System.userDataService.UserData””

  • 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-18T07:15:17+00:00Added an answer on June 18, 2026 at 7:15 am

    ListBox.SelectedItem is of type object, and the ToString() of any object is the type name.

    To get the actual string value, you need to cast listBox2.SelectedItem to your data type first.

    I’m assuming your SelectedItem is of type UserData based on the name it’s giving you with .ToString(), so use something like this:

    ((UserData)listBox2.SelectedItem).ToString();
    

    Or if you want limit to equal the DisplayMemberPath

    ((UserData)listBox2.SelectedItem).MonthlyHourLimit;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Basically try to do the same as: UPDATE table SET column3 = column1 +
Started recently, basically every time I try to fetch or commit it gives me
I' still newby to this so I'll try to explain what I'm doing. Basically
Basically I need to get older version of a file in the repository without
I am try to move all my static content to a CDN to improve
I'm trying to move the position of the seekbar using a button. Basically I
I get a SocketException: Bad file number whenever I try to use a BufferedReader
So basically when I try to draw more a mesh inside an FBX file
Basically I want to check the extended permissions the user has granted my app.
Basically I want to convert a virtual path to an absolute path.

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.