For my Location Service in F# I needed a way to be able to return XML from MVC (which powers my site), but I couldn’t find a way to do this out of the box with XML.
Luckily creating your very own ActionResult is really quite easy in MVC.
First you need to implement the ActionResult class:
public class XmlActionResult : ActionResult { public override void ExecuteResult(ControllerContext context) { } } I’m going to add a couple of public properties:
ASP.NET MVC XML Action Result
For my Location Service in F# I needed a way to be able to return XML from MVC (which powers my site), but I couldn’t find a way to do this out of the box with XML.
Luckily creating your very own ActionResult is really quite easy in MVC.
First yo…
Print
Share
Comment
Cite
Upload
Translate
APA
Posts on LINQ to Fail | Sciencx (2024-03-28T11:53:05+00:00) » ASP.NET MVC XML Action Result. Retrieved from https://www.scien.cx/2010/06/16/asp-net-mvc-xml-action-result/.
MLA" » ASP.NET MVC XML Action Result." Posts on LINQ to Fail | Sciencx - Wednesday June 16, 2010, https://www.scien.cx/2010/06/16/asp-net-mvc-xml-action-result/
HARVARDPosts on LINQ to Fail | Sciencx Wednesday June 16, 2010 » ASP.NET MVC XML Action Result., viewed 2024-03-28T11:53:05+00:00,<https://www.scien.cx/2010/06/16/asp-net-mvc-xml-action-result/>
VANCOUVERPosts on LINQ to Fail | Sciencx - » ASP.NET MVC XML Action Result. [Internet]. [Accessed 2024-03-28T11:53:05+00:00]. Available from: https://www.scien.cx/2010/06/16/asp-net-mvc-xml-action-result/
CHICAGO" » ASP.NET MVC XML Action Result." Posts on LINQ to Fail | Sciencx - Accessed 2024-03-28T11:53:05+00:00. https://www.scien.cx/2010/06/16/asp-net-mvc-xml-action-result/
IEEE" » ASP.NET MVC XML Action Result." Posts on LINQ to Fail | Sciencx [Online]. Available: https://www.scien.cx/2010/06/16/asp-net-mvc-xml-action-result/. [Accessed: 2024-03-28T11:53:05+00:00]
rf:citation » ASP.NET MVC XML Action Result | Posts on LINQ to Fail | Sciencx | https://www.scien.cx/2010/06/16/asp-net-mvc-xml-action-result/ | 2024-03-28T11:53:05+00:00
https://github.com/addpipe/simple-recorderjs-demo