ASP.NET Webforms CRUD scaffolding with Entity Framework 5 - webforms

Back in Feb MS introduced:
http://www.nuget.org/packages/Microsoft.AspNet.Scaffolding.WebForms/
http://blogs.msdn.com/b/webdev/archive/2013/02/20/pre-release-of-asp-net-scaffolding-with-a-web-forms-scaffold-generator.aspx
but it appears that it will be dropped from VS2013
ASP.NET Web Forms Scaffolding feature missing in VS 2013 RC
I followed the instructions here
http://dotnetguts.blogspot.com.au/2013/06/scaffolding-for-aspnet-webforms.html
to install the package under Visual Studio 2012 but when I go to add a scaffold the scaffold generator drop down is empty.
So my question is has anyone come across a free ASP.NET Webforms scaffolding solution that can be used with Entity Framework 5?

here it is, http://visualstudiogallery.msdn.microsoft.com/a6c3614f-83be-4749-afbc-8da394b6ea86
and the explanation here http://blogs.msdn.com/b/webdev/archive/2014/05/13/improvements-to-asp-net-web-forms.aspx?CommentPosted=true#commentmessage

Related

Entity Framework not appearing in Add New Item list in Visual Studio 2017

I created a new MVC project in Visual Studio 2017. I wanted to add an EDMX file (I will be doing database-first) so right clicked on the project and selected Add|New Item.
However, I cannot find the Entity Framework components that were available in the previous versions of Visual Studio. Does anyone know where they went?
I had a similar issue today after i updated my VS to the latest 2017 version. I tried to open an .edmx file in VS2017 and it didn't show the designer view. So i realised i forgot to select Entity Framework tools during the installation:
Everything is back to normal :)
In .NET Framework-based projects, the Entity Framework 6 templates are still there. However, for .NET Core-based projects, I believe you're expected to use the dotnet ef commands. This includes a means of scaffolding a code-first DbContext from an existing database. See ASP.NET Core - Existing Database.
To verify this, I setup a demo project with the following structure:
The New Item/Data dialog for the .NET Framework project:
Note that there is also an EF POCO Generator template available in the Online templates section that may be of interest to you:
I know this is late, but I ran into the same exact issue. After reading some of the other answers, I realized I had created a .Net project with Standard library instead of the Framework library.
I faced this issue, while creating an MVC application on my latest installation of VS2017.
Failed:
Tried installing Entity Framework using Nuget package manager[Install-Package EntityFramework], but failed to show Ado.NET Entity data model
Success:
1. open programs under control panel and select Visual Studio 2017
2. select Change the installation
3. Select Modify installation
4. Select Individual components
5. If SQL server data tools already installed, deselect/uninstall this component and reinstall the same again.
6. uninstall and reinstall SQL Server Data tools
Note: with one component change, other components may also be deleted. You have to recheck while reinstalling

Creating web application using VS 2015 Update 3 creates with references 1.0.0-rc2-final

Creating a web application as ASP.NET Core Web Applicaiton (.NET Framework) creates with most of the references as 1.0.0-rc2-final.
I am using the RTM version of VS 2015 Update 3. Hoping the references to be full version rather than rc2-final.
Are the templates updated properly? Do I need an update for the tools? If needed, where will I get it?
Thanks
ASP.Net Core tooling isn't included in Update 3 so apart from Update 3 you also need to install Web tooling. Go to: https://www.microsoft.com/net/download and download ".NET Core Tooling Preview 2 for Visual Studio 2015" (at the bottom of the page).
Probably going to have to update the project with nuget or by hand this assumes you have installed the SDK Core Preview2 Tooling located here.
NET Core 1.0 for Visual Studio
NB: while the framework has RTM'd the tooling is still in preview status since they are still working on it, hence Preview2 status.
if you have a Global.json file I would also suggest clearing out the entry that says "sdk": {}

How to scaffold views from controller separately

I'm wondering if Visual Studio 2013 has any way to scaffold views using the controllers in MVC. I want to use a repository pattern, so for now I created that myself, and I would like to generate the views.
In Visual Studio 2012 I used the technique explained here by Scott Hanselman, but with the new scaffolding introduced in the new version of Visual Studio I was wondering if this is not supported natively
The scaffolding functionality appears to be embedded in Common7\IDE\Extensions\Microsoft\Web\Mvc\Scaffolding\Microsoft.AspNet.Scaffolding.Mvc.5.0.dll and I can't find any way to customize it further. So if there isn't a built-in means of scaffolding the way their used to be, it looks like you're doing to have to roll your own mechanism.

How do I install MVC3 on a server without using the Web Platform Installer (and without Visual Studio)?

How do I install MVC3 on a server without using the Web Platform Installer (and without Visual Studio)?
I can't seem to locate a standalone installer, and the server won't have VS, and I can't ensure that all the apps will have the binaries included to run it on native .NET4.
Is the only way to install MVC3 support with VS support, even if VS isn't around?
In case it isn't obvious, I'm trying to give the IT group a baseline of packages to install, and the easiest way to do that is to give them the binaries and a few scripts
Referencing the link on http://www.asp.net/mvc/mvc3 we get a link to http://www.microsoft.com/en-us/download/details.aspx?id=1491 | ASP.NET MVC 3 Tools Update
I think that's what you're looking for.
ASP.NET MVC 3 is a framework for developing highly testable and maintainable Web applications by leveraging the Model-View-Controller (MVC) pattern. The framework encourages developers to maintain a clear separation of concerns among the responsibilities of the application – the UI logic using the view, user-input handling using the controller, and the domain logic using the model. ASP.NET MVC applications are easily testable using techniques such as test-driven development (TDD).
The installation package includes templates and tools for Visual Studio 2010 to increase productivity when writing ASP.NET MVC applications. For example, the Add View dialog box takes advantage of customizable code generation (T4) templates to generate a view based on a model object. The default project template allows the developer to automatically hook up a unit-test project that is associated with the ASP.NET MVC application.
You can download it from : https://www.microsoft.com/es-es/download/details.aspx?id=4211
Is the 3.0.0.0 version and you can reference manually the DLL from : C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET MVC 3\Assemblies\System.Web.Mvc.dll
Other versions : https://stackoverflow.com/a/5485175/5775048
Install the MVC3 runtime from this link: http://www.microsoft.com/en-us/download/details.aspx?id=4211.
Go to c:\windows\microsoft.net\framework[64]\v4.0.30319 and run aspnet_regiis -i (adjusting for whatever version of .Net is appropriate).
Restart IIS.
This has always worked for me, although at the moment I'm having an issue because the installer installs 3.0.0.0 and my app is looking for 3.0.0.1.

Open an exising MVC 3 project in visual studio 11 developer preview

I've trying to open and convert an existing vs 2010 mvc 3 project in the new dev 11 preview and am running in to a difficult issue. The solution file will convert successfully, however the one mvc 3 web project in the solution shows in the solution explorer as unloaded post conversion. When i attempt to reload the project from solution explorer, i get prompted to convert the project and receive the following error in the upgradelog.xml
The project file'myproject.csproj' cannot be opened. There is a missing project subtype. Subtype: '{E53F8FEA-EAE0-44A6-8774-FFD645390401}' is unsupported by this installation.
From what i could track down, this has to do with MVC, but that doesn't really help me work around the issue. Any suggestions or workarounds would be appreciated.
Update: Actually, MVC 3 for Visual Studio 11 Dev Preview has just been published: http://www.microsoft.com/download/en/details.aspx?id=1491
We have not yet shipped MVC 3 support in Visual Studio 11. You can work around this by editing your csproj file and removing the project type GUID {E53F8FEA-EAE0-44A6-8774-FFD645390401}. This will cause your project to load like a normal WAP. You will be able to edit your code, however MVC-specific actions (Add Controller, etc) will not be available.
You may want to try the steps from the Upgrading an ASP.NET MVC 3 Project to ASP.NET MVC 4 section of the release notes, even if the document describes the VS2010 version.
I managed to convert a VS2010/MVC3 project, but VS11 shows a warning every time I open the solution, stating that the project requires ASP.NET Web pages with Razor syntx 1.0. OTOH, the project seems to run without any problems (VS11 setup also installed ASP.NET Web pages 2).

Resources