Questions tagged [asp.net-mvc-scaffolding]

ASP.NET MVC Scaffolding is a scaffolding package for quickly generating a basic outline of your software that you can then edit and customise.

ASP.NET MVC Scaffolding is a scaffolding package for quickly generating a basic outline of your software that you can then edit and customise.

A tutorial is found on Steven Sanderson's blog.

Installation

MVC Scaffolding can most easily be installed through its NuGet package.

Install-Package MvcScaffolding
364 questions
0
votes
1 answer

Adding Controller using Ado.Net Entity Framework

I am new for MVC, I am trying to add a control in my project. I added Entity Model in Model folder from database. It's name is MyModel.edmx and my entity's name is MyEntities. I followed this path: Controllers -> right click -> Add -> Controller. A…
user2911240
0
votes
1 answer

Error trying to create a MVC Controller in VS 2012

When i right click a folder and click "Add Controller" i get this error: Object reference not set to an instance of an object This error also started to appear in Package Manager Console when i open the project. New-Object : Could not load file or…
0
votes
2 answers

WEB API return all objects instead of one

I want to expose a list of services from my DB or just return one service detail via Web API with my EF DBmodel . I used VS2012 Web API scaffolding, quite easy so far and it works and return the list of services in JSON when I hit the…
0
votes
1 answer

Error when creating a new view using MvcScaffoldingT4TwitterBootstrapMvc Nuget package

I installed the MvcScaffolding4TwitterBootstrapMvc package which is based on the scaffolding stuff Steve Sanderson has done. Now I'm attempting to create a new view based on it and I'm just receiving PS errors. I'm typing this: Scaffold View…
Paul Mrozowski
  • 6,604
  • 9
  • 34
  • 47
0
votes
1 answer

Adding Static Files To Project By T4Scaffolding

I am generating an CMS by using T4Scaffolder and all the CS files are being generated successfully. But also I want to add some css and png files to the project. What is the best way to add static files to MVC Web Application with a powershell…
Barış Velioğlu
  • 5,709
  • 15
  • 59
  • 105
0
votes
2 answers

Passing parameters to method in MvcScaffolders

I am passing values to first two parameters of T4Scaffolding.Scaffolder. But it does not work what I excepted. This is the powershell script file. Lets give it a name as Test.ps1 [T4Scaffolding.Scaffolder(Description = "Enter a description of…
Barış Velioğlu
  • 5,709
  • 15
  • 59
  • 105
0
votes
1 answer

How scaffold Durandal, Breeze in SPA app with VS 2012

I'm starting to develop an application based on Hot Towel project template. The question is how I can scaffold Durandal? I want to perform code generation like mvc scaffolding, but for SPA using Hot Towel template, to accelerate the development of…
Adrian
  • 7,745
  • 5
  • 28
  • 28
0
votes
0 answers

How can I achieve following using MVC scaffolding?

I have an SQL Server 2008 database. All tables having a GUID as the primary key, and they are NOT auto-generated. Rather, I want my code to generate it and pass it in INSERT operation. Some of the tables are having one-to-one or one-to-many…
Nirman
  • 6,715
  • 19
  • 72
  • 139
0
votes
1 answer

Get The Table Name Of Model In T4 Template

I am using MVC4 ,T4 Scaffolding and EF5. I Created a model, namespace wbtest.Models { [Table(name: "Pay_Employees_Mst", Schema = "Test")] public class Employee { public int EMPLOYEE_ID { get; set; } public string EMPLOYEE_CODE { get; set;…
0
votes
1 answer

Confused with MVC scaffolding

I'm learning MVC3. There is something I'm trying from many hours and now I think I'm totally lost. I created a database first, then generated Models from it. Now I wanna know if it is possible to use scaffolding to generate a model with CRUD views?…
vish213
  • 748
  • 3
  • 12
  • 27
0
votes
1 answer

MVC Scaffolding with Repository Pattern - Saving children objects as a transaction

I have been scouring forums and repository pattern blogs for some clear direction on how I should be coding my project and I'm stuck. Any help or guidance from you guys would be much approciated :) I started my project as EF5 MVC4 Razor Code First…
0
votes
1 answer

Nuget error after adding AzureCloudServce to existing MVC4 app

I have an MVC 4 application that I want to convert to an Azure Cloud Service. These are the steps I took: Update-Package to get everything on the latest I followed the steps at this blog Build Solution (succeeds) F5 -> Get error that VS2012 needs…
0
votes
1 answer

T4Scaffolding access generic collection T properties

Given the following class: public class Post { public Post() { Tags = new List(); } public int Id { get; set; } // ...more properties... public virtual ICollection Tags { get; set; } } and my ps1 entry…
Leblanc Meneses
  • 3,001
  • 1
  • 23
  • 26
0
votes
1 answer

MVC4 - How to rearrange generated fields created by Scaffolding

I have a .cshtml file created by MVC4 scaffolding that looks something like this: @using (Html.BeginForm()) { @Html.ValidationSummary(true)
BicycleSellerListing
Hosea146
  • 7,412
  • 21
  • 60
  • 81
0
votes
2 answers

MVC 4 Scaffold Delete Issue with ID

I created scaffold delete view for delete but it doesn't work. When debugging I found that It doesnt pass the correct ID of the record to controller. Always it passes 0 as the ID and result is an exception (ystem.NullReferenceException was unhandled…
chatura
  • 4,097
  • 4
  • 19
  • 19