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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T09:26:08+00:00 2026-06-05T09:26:08+00:00

In this question the Answer suggests using an object as the parameter. What URL

  • 0

In this question the Answer suggests using an object as the parameter. What URL would I use to access that?
In the OP’s first example, my original approach was to overload the action (not sure if overload is the right word) so I had:

public IEnumerable<NTOrder> Get()...

public IEnumerable<NTOrder> Get(int p)...

public IEnumerable<NTOrder> Get(int p, int q)

not elegant, I know, but if I change it to one object I don’t know how to format the URL…

Old Code

public IEnumerable<NTOrder> Get() {
    //build NTOrderList
    return NTOrderList;
}

New Code

public class FilterView
{
    public int? fID { get; set; }
    public int? fCustomer { get; set; }
    public string fSalesPerson{ get; set; }
}

public IEnumerable<NTOrder> Get(FilterView queryFilter) {
    //build NTOrderList
    List<NTOrder> result = (from order in NTOrderList
                               where (order.OrderID == queryFilter.fID || queryFilter.fID == null)
                                  && (order.CustomerID == queryFilter.fCustomer || queryFilter.fCustomer == null)
                                  && (queryFilter.fSalesPerson == null || order.Salesperson.Equals(queryFilter.fSalesPerson))
                                select order).ToList();

    return result;
}
  • 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-05T09:26:09+00:00Added an answer on June 5, 2026 at 9:26 am

    I found this answer as a possible solution, which basically suggests passing the data as JSON in the url and adding a filter to convert that to a complex object, but as the OP in that post suggests it’s not the most elegant way…anybody have a more elegant solution?

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

Sidebar

Related Questions

This answer to a question about C++ unit test frameworks suggests a possibility that
I am trying to integrated linkedIn using this question answer Posting LinkedIn message from
While trying to answer this question I found that the code int* p =
This is a continuation of this question: Original Question (SO) The answer to this
I am basing my question and example on Jason's answer in this question I
This question and my answer below are mainly in response to an area of
While trying to answer this question I found without () (which invokes C++ most
I read this question but the answer does not perform a refactoring of the
Thanks in Advance for reading and answer this question. I got button in asp
Also can you please answer this question? how do I get co-ordinates of selected

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.