Click here to Skip to main content
Click here to Skip to main content
 
Add your own
alternative version

Custom ASP.NET MVC ActionResults

, 23 Sep 2013
Implementing custom ActionResult. Here we shall see how to build a custom ActionResult to return XML and RSS feeds.
MvcXmlActionResult-noexe.zip
MvcXmlActionResult
MvcXmlActionResult.v11.suo
MvcXmlActionResult
App_Start
bin
Content
themes
base
images
ui-bg_flat_0_aaaaaa_40x100.png
ui-bg_flat_75_ffffff_40x100.png
ui-bg_glass_55_fbf9ee_1x400.png
ui-bg_glass_65_ffffff_1x400.png
ui-bg_glass_75_dadada_1x400.png
ui-bg_glass_75_e6e6e6_1x400.png
ui-bg_glass_95_fef1ec_1x400.png
ui-bg_highlight-soft_75_cccccc_1x100.png
ui-icons_222222_256x240.png
ui-icons_2e83ff_256x240.png
ui-icons_454545_256x240.png
ui-icons_888888_256x240.png
ui-icons_cd0a0a_256x240.png
minified
images
ui-bg_flat_0_aaaaaa_40x100.png
ui-bg_flat_75_ffffff_40x100.png
ui-bg_glass_55_fbf9ee_1x400.png
ui-bg_glass_65_ffffff_1x400.png
ui-bg_glass_75_dadada_1x400.png
ui-bg_glass_75_e6e6e6_1x400.png
ui-bg_glass_95_fef1ec_1x400.png
ui-bg_highlight-soft_75_cccccc_1x100.png
ui-icons_222222_256x240.png
ui-icons_2e83ff_256x240.png
ui-icons_454545_256x240.png
ui-icons_888888_256x240.png
ui-icons_cd0a0a_256x240.png
Controllers
CustomActionResults
favicon.ico
Global.asax
Images
accent.png
bullet.png
heroAccent.png
orderedList0.png
orderedList1.png
orderedList2.png
orderedList3.png
orderedList4.png
orderedList5.png
orderedList6.png
orderedList7.png
orderedList8.png
orderedList9.png
MvcXmlActionResult.csproj.user
obj
Debug
Properties
PublishProfiles
Test.pubxml
Test.pubxml.user
Scripts
Views
Home
Shared
packages
EntityFramework.5.0.0
Content
App.config.transform
Web.config.transform
EntityFramework.5.0.0.nupkg
lib
net40
net45
tools
EntityFramework.PS3.psd1
EntityFramework.psd1
EntityFramework.psm1
init.ps1
install.ps1
jQuery.1.7.1.1
Content
Scripts
jQuery.1.7.1.1.nupkg
Tools
common.ps1
install.ps1
uninstall.ps1
jQuery.UI.Combined.1.8.20.1
Content
Content
themes
base
images
ui-bg_flat_0_aaaaaa_40x100.png
ui-bg_flat_75_ffffff_40x100.png
ui-bg_glass_55_fbf9ee_1x400.png
ui-bg_glass_65_ffffff_1x400.png
ui-bg_glass_75_dadada_1x400.png
ui-bg_glass_75_e6e6e6_1x400.png
ui-bg_glass_95_fef1ec_1x400.png
ui-bg_highlight-soft_75_cccccc_1x100.png
ui-icons_222222_256x240.png
ui-icons_2e83ff_256x240.png
ui-icons_454545_256x240.png
ui-icons_888888_256x240.png
ui-icons_cd0a0a_256x240.png
minified
images
ui-bg_flat_0_aaaaaa_40x100.png
ui-bg_flat_75_ffffff_40x100.png
ui-bg_glass_55_fbf9ee_1x400.png
ui-bg_glass_65_ffffff_1x400.png
ui-bg_glass_75_dadada_1x400.png
ui-bg_glass_75_e6e6e6_1x400.png
ui-bg_glass_95_fef1ec_1x400.png
ui-bg_highlight-soft_75_cccccc_1x100.png
ui-icons_222222_256x240.png
ui-icons_2e83ff_256x240.png
ui-icons_454545_256x240.png
ui-icons_888888_256x240.png
ui-icons_cd0a0a_256x240.png
Scripts
jQuery.UI.Combined.1.8.20.1.nupkg
jQuery.Validation.1.9.0.1
Content
Scripts
jQuery.Validation.1.9.0.1.nupkg
knockoutjs.2.1.0
Content
Scripts
knockoutjs.2.1.0.nupkg
Microsoft.AspNet.Mvc.4.0.20710.0
lib
net40
Microsoft.AspNet.Mvc.4.0.20710.0.nupkg
Microsoft.AspNet.Razor.2.0.20710.0
lib
net40
Microsoft.AspNet.Razor.2.0.20710.0.nupkg
Microsoft.AspNet.Web.Optimization.1.0.0
Microsoft.AspNet.Web.Optimization.1.0.0.nupkg
Microsoft.AspNet.WebApi.4.0.20710.0
Microsoft.AspNet.WebApi.4.0.20710.0.nupkg
Microsoft.AspNet.WebApi.Client.4.0.20710.0
lib
net40
Microsoft.AspNet.WebApi.Client.4.0.20710.0.nupkg
Microsoft.AspNet.WebApi.Core.4.0.20710.0
content
web.config.transform
lib
net40
Microsoft.AspNet.WebApi.Core.4.0.20710.0.nupkg
Microsoft.AspNet.WebApi.WebHost.4.0.20710.0
lib
net40
Microsoft.AspNet.WebApi.WebHost.4.0.20710.0.nupkg
Microsoft.AspNet.WebPages.2.0.20710.0
lib
net40
Microsoft.AspNet.WebPages.2.0.20710.0.nupkg
Microsoft.jQuery.Unobtrusive.Ajax.2.0.20710.0
Content
Scripts
Microsoft.jQuery.Unobtrusive.Ajax.2.0.20710.0.nupkg
Microsoft.jQuery.Unobtrusive.Validation.2.0.20710.0
Content
Scripts
Microsoft.jQuery.Unobtrusive.Validation.2.0.20710.0.nupkg
Microsoft.Net.Http.2.0.20710.0
lib
net40
net45
_._
Microsoft.Net.Http.2.0.20710.0.nupkg
Microsoft.Web.Infrastructure.1.0.0.0
Microsoft.Web.Infrastructure.1.0.0.0.nupkg
Modernizr.2.5.3
Content
Scripts
Modernizr.2.5.3.nupkg
Newtonsoft.Json.4.5.6
lib
net40
Newtonsoft.Json.4.5.6.nupkg
WebGrease.1.1.0
WebGrease.1.1.0.nupkg
MvcXmlActionResult.zip
MvcXmlActionResult.v11.suo
Antlr3.Runtime.dll
EntityFramework.dll
Microsoft.Web.Infrastructure.dll
MvcXmlActionResult.dll
Newtonsoft.Json.dll
System.Net.Http.Formatting.dll
System.Web.Helpers.dll
System.Web.Http.dll
System.Web.Http.WebHost.dll
System.Web.Mvc.dll
System.Web.Optimization.dll
System.Web.Razor.dll
System.Web.WebPages.Deployment.dll
System.Web.WebPages.dll
System.Web.WebPages.Razor.dll
WebGrease.dll
ui-bg_flat_0_aaaaaa_40x100.png
ui-bg_flat_75_ffffff_40x100.png
ui-bg_glass_55_fbf9ee_1x400.png
ui-bg_glass_65_ffffff_1x400.png
ui-bg_glass_75_dadada_1x400.png
ui-bg_glass_75_e6e6e6_1x400.png
ui-bg_glass_95_fef1ec_1x400.png
ui-bg_highlight-soft_75_cccccc_1x100.png
ui-icons_222222_256x240.png
ui-icons_2e83ff_256x240.png
ui-icons_454545_256x240.png
ui-icons_888888_256x240.png
ui-icons_cd0a0a_256x240.png
ui-bg_flat_0_aaaaaa_40x100.png
ui-bg_flat_75_ffffff_40x100.png
ui-bg_glass_55_fbf9ee_1x400.png
ui-bg_glass_65_ffffff_1x400.png
ui-bg_glass_75_dadada_1x400.png
ui-bg_glass_75_e6e6e6_1x400.png
ui-bg_glass_95_fef1ec_1x400.png
ui-bg_highlight-soft_75_cccccc_1x100.png
ui-icons_222222_256x240.png
ui-icons_2e83ff_256x240.png
ui-icons_454545_256x240.png
ui-icons_888888_256x240.png
ui-icons_cd0a0a_256x240.png
favicon.ico
Global.asax
accent.png
bullet.png
heroAccent.png
orderedList0.png
orderedList1.png
orderedList2.png
orderedList3.png
orderedList4.png
orderedList5.png
orderedList6.png
orderedList7.png
orderedList8.png
orderedList9.png
MvcXmlActionResult.csproj.user
MvcXmlActionResult.dll
Test.pubxml
Test.pubxml.user
App.config.transform
Web.config.transform
EntityFramework.5.0.0.nupkg
EntityFramework.dll
EntityFramework.dll
EntityFramework.PowerShell.dll
EntityFramework.PowerShell.Utility.dll
EntityFramework.PS3.psd1
EntityFramework.psd1
EntityFramework.psm1
init.ps1
install.ps1
migrate.exe
jQuery.1.7.1.1.nupkg
common.ps1
install.ps1
uninstall.ps1
ui-bg_flat_0_aaaaaa_40x100.png
ui-bg_flat_75_ffffff_40x100.png
ui-bg_glass_55_fbf9ee_1x400.png
ui-bg_glass_65_ffffff_1x400.png
ui-bg_glass_75_dadada_1x400.png
ui-bg_glass_75_e6e6e6_1x400.png
ui-bg_glass_95_fef1ec_1x400.png
ui-bg_highlight-soft_75_cccccc_1x100.png
ui-icons_222222_256x240.png
ui-icons_2e83ff_256x240.png
ui-icons_454545_256x240.png
ui-icons_888888_256x240.png
ui-icons_cd0a0a_256x240.png
ui-bg_flat_0_aaaaaa_40x100.png
ui-bg_flat_75_ffffff_40x100.png
ui-bg_glass_55_fbf9ee_1x400.png
ui-bg_glass_65_ffffff_1x400.png
ui-bg_glass_75_dadada_1x400.png
ui-bg_glass_75_e6e6e6_1x400.png
ui-bg_glass_95_fef1ec_1x400.png
ui-bg_highlight-soft_75_cccccc_1x100.png
ui-icons_222222_256x240.png
ui-icons_2e83ff_256x240.png
ui-icons_454545_256x240.png
ui-icons_888888_256x240.png
ui-icons_cd0a0a_256x240.png
jQuery.UI.Combined.1.8.20.1.nupkg
jQuery.Validation.1.9.0.1.nupkg
knockoutjs.2.1.0.nupkg
System.Web.Mvc.dll
Microsoft.AspNet.Mvc.4.0.20710.0.nupkg
System.Web.Razor.dll
Microsoft.AspNet.Razor.2.0.20710.0.nupkg
lib
net40
System.Web.Optimization.dll
Microsoft.AspNet.Web.Optimization.1.0.0.nupkg
Microsoft.AspNet.WebApi.4.0.20710.0.nupkg
System.Net.Http.Formatting.dll
Microsoft.AspNet.WebApi.Client.4.0.20710.0.nupkg
web.config.transform
System.Web.Http.dll
Microsoft.AspNet.WebApi.Core.4.0.20710.0.nupkg
System.Web.Http.WebHost.dll
Microsoft.AspNet.WebApi.WebHost.4.0.20710.0.nupkg
System.Web.Helpers.dll
System.Web.WebPages.Deployment.dll
System.Web.WebPages.dll
System.Web.WebPages.Razor.dll
Microsoft.AspNet.WebPages.2.0.20710.0.nupkg
Microsoft.jQuery.Unobtrusive.Ajax.2.0.20710.0.nupkg
Microsoft.jQuery.Unobtrusive.Validation.2.0.20710.0.nupkg
System.Net.Http.dll
System.Net.Http.WebRequest.dll
_._
Microsoft.Net.Http.2.0.20710.0.nupkg
lib
net40
Microsoft.Web.Infrastructure.dll
Microsoft.Web.Infrastructure.1.0.0.0.nupkg
Modernizr.2.5.3.nupkg
Newtonsoft.Json.dll
Newtonsoft.Json.4.5.6.nupkg
lib
Antlr3.Runtime.dll
WebGrease.dll
tools
WG.exe
WebGrease.1.1.0.nupkg

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Ranjan.D
Web Developer
United States United States
Profile
 
Around 9 years of professional software development experience in analysis, design, development, testing and implementation of enterprise web applications for healthcare domain with good exposure to object-oriented design, software architectures, design patterns, test-driven development and agile practices.
 
In Brief
 
Analyse and create High Level , Detailed Design documents.
Use UML Modelling and create Use Cases , Class Diagram , Component Model , Deployment Diagram, Sequence Diagram in HLD.
 
Area of Working : Dedicated to Microsoft .NET Technologies
Experience with : C# , J2EE , J2ME, Windows Phone 8, Windows Store App
Proficient in: C# , XML , XHTML, XML, HTML5, Javascript, Jquery, CSS, SQL, LINQ, EF
 
Software Development
 
Database: Microsoft SQL Server, FoxPro
Development Frameworks: Microsoft .NET 1.1, 2.0, 3.5, 4.5
UI: Windows Forms, Windows Presentation Foundation, ASP.NET Web Forms and ASP.NET MVC3, MVC4
Coding: WinForm , Web Development, Windows Phone, WinRT Programming, WCF, WebAPI
 
Healthcare Domain Experience
 
CCD, CCR, QRDA, HIE, HL7 V3, Healthcare Interoperability
 
Others:
 
TTD, BDD
 
Education
 
B.E (Computer Science)
 
CodeProject Contest So Far:
 
1. Windows Azure Developer Contest - HealthReunion - A Windows Azure based healthcare product , link - http://www.codeproject.com/Articles/582535/HealthReunion-A-Windows-Azure-based-healthcare-pro
 
2. DnB Developer Contest - DNB Business Lookup and Analytics , link - http://www.codeproject.com/Articles/618344/DNB-Business-Lookup-and-Analytics
 
3. Intel Ultrabook Contest - Journey from development, code signing to publishing my App to Intel AppUp , link - http://www.codeproject.com/Articles/517482/Journey-from-development-code-signing-to-publishin
 
4. Intel App Innovation Contest 2013 - eHealthCare - http://www.codeproject.com/Articles/635815/eHealthCare
 
5. Grand Prize Winner of CodeProject HTML5 &CSS3 Article Content 2014

| Advertise | Privacy | Mobile
Web03 | 2.8.140826.1 | Last Updated 23 Sep 2013
Article Copyright 2013 by Ranjan.D
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid