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

  • Home
  • SEARCH
  • 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 7913849
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T13:56:19+00:00 2026-06-03T13:56:19+00:00

current situation: an ASP.NET MVC web site with a number of controllers and action

  • 0

current situation: an ASP.NET MVC web site with a number of controllers and action methods, and views to allow adding recipes.

Now, I have to create a WPF application that acts as a UI to add recipes (same as the web site).

My question is: can I use ASP.NET MVC site to expose service operations that are consumed by the WPF application (and how can this be done)? Or should I better create dedicated WCF services for that, and have the WPF AND the ASP.NET MVC site consume these services?

Thanks,
Ludwig

  • 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-03T13:56:20+00:00Added an answer on June 3, 2026 at 1:56 pm

    I have successfully used MVC controllers and actions to service both HTML views from the browser, as well as external applications. It works well, but as it stands you’d need a little bit of tooling:

    1. I have an action filter that returns the Model resulting from an action in a format the client requested (by inspecting the Accepts header, looking for either application/json or text/xml). So, I can serialize the resulting model as JSON or XML (I prefer JSON).
    2. You will need to find or create a simple API in your client application to create WebRequests to your actions, and then process the results. I created a simple API that can POST or GET, and then deserializes any resulting JSON into an object (using JSON.NET). There are REST client APIs out there you could use for this.

    However, you could avoid some of this extra tooling if you go the WCF-REST route. Better yet, I’d look into ASP.NET MVC 4’s WebApi feature (which is what I will be migrating to).

    For the record, I think WCF is powerful, but our organization has grown tired of how complicated it can be to turn all the knobs and hit all the switches to get it working right, and set up easily from one install to the other. MVC, on the other hand, just works… and since we already use it to service our HTML views, it’s a real joy to only have to add a little extra code to have it handle service calls, too. Just a personal preference, of course.

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

Sidebar

Related Questions

in my current ASP.net MVC 3.0 project i am stuck with a situation. I
I am developing a web application in asp.net vb. My current situation is, I
I am using Asp.Net/C# in my application.My current situation is that I am using
While writing some aysnc controllers in ASP.NET MVC2, I ran up against a situation
Here's the situation : I have an ASP.NET PasswordRecovery ( http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.passwordrecovery.aspx ) control used
Here is the situation: C# Windows Forms application ASP.NET web application Both authenticate with
Have just started playing with ASP.NET MVC and have stumbled over the following situation.
let me explain my current situation i have a SharePoint site lets say it
Situation:I have an ASP .NET application that will search through docs using Lucene. I
I have an ASP.NET site that I am maintaining. Currently it has code that

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.