Sharp Architecture is based on the ASP.NET MVC framework with some additions like NHibernate. Helps the developer gain some time without having to worry about the details of getting the MVC framework and data layer exchange running along with all the groundwork. Below is my take on Sharp Architecture 1.0.2009 Q3 release setup in Visual Studio 2008 from their well documented wiki.
Download and Installation
- Download Sharp Architecture from their github download page: http://github.com/codai/Sharp-Architecture/downloads
- Unzip and click “ClickToBuild.bat” (required if you want to open the source code in Visual Studio, otherwise you can skip this step)
- Download and Install T4 Toolbox (http://www.codeplex.com/t4toolbox) needed for CRUD scaffolding.
- Copy “SharpArchApplicationTemplate.zip” from “VisualStudioTemplate” directory to your Visual Studio 2008 Project Templates folder (C:\Documents and Settings\{username}\My Documents\Visual Studio 2008\Templates\ProjectTemplates\Visual C#\Web). If subdirectory “Web” does not exist you can create one, it will help to keep all templates organized.
- From the same “VisualStudioTemplate” directory copy “SharpArchApplicationWizard.dll” to “C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE”
Create a Sharp Architecture Web Project in Visual Studio 2008
- Open Visual Studio 2008
- Go to File -> New -> Project
- Under Visual C# , select Web –> My Templates –> S#arp Architecture Application.
- Enter a project name with NO SPACES.
- Keep “Create directory for solution” unchecked or it will add a new parent folder.
- Click “OK”
If you get an error message like this one: “Error: this template attempted to load an untrusted component ‘SharpArchApplicationWizard, Version=1.0.0.0 …‘. For more information on this problem and how to enable this template, please see…”, then try this:
- If running on a 64-bit OS then drop “SharpArchApplicationWizard.dll” into “C:\Program Files (x86)\Microsoft Visual Studio 9.0\Common7\IDE” instead.
- Try re-registering project or item templates located in Visual Studio’s template directories.
- Close VS2008
- Open Programs => Microsoft Visual Studio 2008 => Visual Studio Tools => Visual Studio 2008 Command Prompt
- Type “devenv.exe /InstallVSTemplates” and press Enter
- Add DLL to GAC:
- Close VS 2008
- Programs => Administrative Tools => .Net Framework 2.0 Configuration
- Click “Manage Assembly Cache”
- Click “Add an Assembly to the Assembly Cache”
- Add “SharpArchApplicationWizard.dll”
- This should add the DLL to the GAC.
- Try creating your project again.
No Responses