You use scaffolding to generate code in your presentation projects. Refer to Overview of Scaffolding for more information.
To invoke scaffolding, perform the following procedure:
Click Build and select Build Solution to build the solution.
In Solution Explorer, navigate to a presentation project that supports scaffolding. This includes the following project types:
MVC Web Application Project. Refer to Creating an MVC Web Application for more information.
Web API RESTful Service Project. Refer to Creating a RESTful Web Service Application for more information.
WCF Service Application using Scaffolding. Refer to Creating a WCF Service Application using Scaffolding for more information.
If your project type is MVC and you are using areas in your project, navigate to the applicable area folder (for example, Areas/<areaname>, where <areaname> is the name of your area).
Note: An Area is a logical grouping of Controller, Models, Views and other related folders in an MVC application. Areas are an optional feature in ASP.Net MVC. For an example, refer to https://msdn.microsoft.com/en-us/library/ee671793(v=vs.100).aspx.
If you want to scaffold a single view using the Scaffold Unisys View Dialog, navigate to the folder where the file is to be placed.
For example, navigate to the Views\<controllername> folder, where <controllername> is the name of the controller that you previously scaffolded.
Right-click the presentation project or folder, select Add, then select New Scaffolded Item.
The Add Scaffold dialog opens. This dialog lists scaffolders from Microsoft, Unisys, and possibly other third party vendors.
Select one of the appropriate Unisys-provided scaffolders, described below, and click Add.
Unisys-Provided Scaffolders
Unisys provides the following scaffolders:
Note: The choices that display vary depending on the particular presentation project involved.
Unisys WCF Service for ePortal Data Source
Select this choice to scaffold a WCF Service Application using Scaffolding. The Scaffold Unisys WCF Service for ePortal Data Source Dialog opens.
Unisys Web API Controller for ePortal Data Source
Select this choice to scaffold the controller for a Web API RESTful Service Project. The Scaffold Unisys Web API Controller for ePortal Data Source Dialog opens.
Unisys Controller for ePortal Data Source with Views
Select this choice to scaffold the controller and the views for an MVC Web Application Project. The Scaffold Unisys Controller for ePortal Data Source with Views Dialog opens.
Unisys Controller for ePortal Data Source
Select this choice to scaffold the just the controller (but no views) for an MVC Web Application Project. The Scaffold Unisys View Dialog opens.
Unisys View
Select this choice to scaffold one single view for an MVC Web Application Project. The Scaffold Unisys View Dialog opens.