Top "Asp.net-apicontroller" questions

How to return JSON in an ApiController for a single method?

Currently, my ApiControllers are returning XML as a response, but for a single method, I want to return JSON. i.…

c# asp.net-mvc asp.net-web-api asp.net-web-api2 asp.net-apicontroller
An error occurred when trying to create a controller of type 'TypeNewsController'

I have searched long and hard but found nothing that helped yet. Where am I going wrong? I really do …

asp.net-mvc dependency-injection autofac asp.net-apicontroller
MVC 4 return JSON as ActionResult

i'm trying to get my apicontroller to work. But somehow i cannot return Json(). Here's the error message from the …

c# json asp.net-mvc-4 controller asp.net-apicontroller
Circular references preventing serialization of object graph

I've got a simple data model involving Weeds and Weed Families. WeedFamily <-1---*-> Weed (WeedFamily and …

c# oop asp.net-apicontroller
Need to add custom header to request in unit test

I finally was able to get the HttpContext.Current to be not null by finding some code online. But I …

c# unit-testing httprequest httpcontext asp.net-apicontroller
Passing JSON Array from Javascript to Web API Controller method

I was not able to get the JSON array parameters in web api controller method (SaveDetails). Here are my code. …

asp.net-web-api .net-4.5 arrays asp.net-apicontroller
Calling a Web API page from SSIS?

I have a simple ASP.Net Web API set up that triggers a process. I would like to call this …

asp.net ssis asp.net-apicontroller
ApiController vs ODataController when exposing DTOs

Can someone explain me when I should inherit my controller form ODataController vs ApiController ? The question is caused by the …

.net asp.net-web-api odata dto asp.net-apicontroller
API Controller Post method return type/value

I want to use a .NET Web API 2 Controller for my vb.net game. I added one to my project …

ajax asp.net-web-api2 .net-4.5 asp.net-apicontroller