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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T22:09:19+00:00 2026-05-11T22:09:19+00:00

I decided that returning datasets, working with datasets and datatables in a front end

  • 0

I decided that returning datasets, working with datasets and datatables in a front end app is a rather bad idea. So with the magic of generics I am returning a generic list via Webservice call (not WCF just plain ol’ asmx). That works dandy as long as you need to return one list per call to your webservice.

The scenario I am running into is that I have a more involved screen where there are a few dropdowns and so on. I need to bind those dropdowns to a generic list. Problem is that I don’t want to make several web calls, one for each dropdown, to get my data. In the past I would have just returned a dataset and bound a dropdown to a specific table in the dataset.

So, it would be super to return multiple generic lists in one web call.

Things I’ve tried:

  1. Using a List of Lists
  2. Using a Collection of generic Lists
  3. Creating a base class and using a Collection of List<Base>, there are conversion issues there when trying to stuff objects into that List<Base>.
  4. Creating a class that has properties that return List<MyOneObject>, List<MySecondObject>, etc. That works but it’s kinda messy… I have lots of classes and screens in the app where this would happen. I could create a class like this that has a properties of List<MyType> for each class, but like I said I think that may get out of control.

So at this point I have two options, #4 in the above list, or just return a dataset which I would prefer not to do :0)

Has anyone run into this before?

  • 1 1 Answer
  • 1 View
  • 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-11T22:09:19+00:00Added an answer on May 11, 2026 at 10:09 pm

    Well I don’t think returning multiple lists is a good idea, but if you are going to do it, I would create a wrapper class with each list exposed as a property in that class.

    Something like

    class Wrapper
    {
       public List<object1> Object1List {get;set;}
       public List<object1> Object2List {get;set;}
    
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

My company has decided that we need a generic demo infrastructure for our technology
Ive decided that I really dont like microsoft and their ways. Please could you
I have decided that all my WPF pages need to register a routed event.
I've recently decided that I just have to finally learn C/C++, and there is
I have decided that I really need to get some flowcharts for reverse engineering
I have pretty big background of .net, and I've decided that i want to
I'm an old (but not too old) Java programmer, that decided to learn C++.
Why is it that they decided to make String immutable in Java and .NET
I decided to install APC to speed up the site that I work for.
I have some commits that I've decided, after the fact, are going to be

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.