How to create a DNN module?
The following detailed instructions will guide you through all the steps for creating and running a DNN module. Before we start please make sure that you have all the prerequisites mentioned below
Prerequisites
- Visual Studio 2008, 2010 or 2012
- IIS installed on your Operating System and ASP.NET extensions are installed and enabled.
- .NET 3.5 SP1 installed, DNN 7 requires 4.0+
- SQL 2005/2008/2012
- Visual Studio is running "As Administrator"
Step 1: Install the Aspose DotNetNuke Project Templates
Installing Aspose DotNetNuke project templates is pretty easy. There are multiple ways to install: choose one of these options below.
Install manually by downloading the VSIX file from the DNN Store
- Visit the DNN Store –
Aspose DotNetNuke Module Development Template page
- Click ‘Add to Cart’ and then proceed to checkout to download the VSIX file
- Double click on the downloaded file to install the templates.
Install manually by downloading from Codeplex
- Download the VSIX file from Codeplex
- Double click on the downloaded file to install the templates.
Note: Please make sure to restart Visual Studio for the changes to take effect.
Step 2: Creating a DotNetNuke Module using the Templates
Once you’ve installed the templates, you can set up a project based on them. To do so you should follow the steps below. Before you can use them, you should have installed Visual Studio 2010 or 2012, and Aspose DotNetNuke Project Templates (described
above).
- Set up the DotNetNuke Development environment following the steps in the Wiki (the templates assume you have your development environment set up at http://dnndev.me/).
Development Environment
- Run Visual Studio 2010 or Visual Studio 2012 as an Administrator (right-click the desk-top shortcut to do so)
- From the File menu, select New Project.
- Choose either C# or VB.Net from the Languages section of the new project dialog.
Aspose DotNetNuke create project
- Select the DotNetNuke Folder under your preferred language (C# or Visual Basic).
- Choose either the Aspose DotNetNuke C# Compiled Module or
Aspose DotNetNuke 7 C# DAL2 Compiled Module template for your project template (or the VB.NET versions).
- For the new project creation screen using the following settings
- Name: ModuleName
Something unique here, example DNNTaskManager - Location: c:\websites\dnndev.me\desktopmodules\
This assumes you set up your development environment as instructed in step 1. - Solution: Create new solution
- Create directory for solution : Unchecked
If checked, this option will cause path problems. The templates assume that the SLN is in the same folder as the project file.
- Click OK.
A screen is shown containing all Aspose components (screenshot below).
- Select one or more components from the list.
Each component’s common uses is shown upon selection. - Click Next to continue once done.
Aspose DotNetNuke create project select components
The Next screen shows the download progress for each selected component.
Aspose DotNetNuke create project component download
Once the downloading is completed the module is created with the selection components automatically reference.
Aspose DotNetNuke created module
This creates a folder under c:\websites\dnndev.me\desktopmodules\ModuleName which should contain all the files necessary for your module, including the solution.