Tuesday, August 22, 2017
 Now reading ...
Jun
1
Tue
Posted By Subodh on Tuesday, June 01, 2010
27771 Views 7 Comments


 

Free Dotnetnuke Template for Visual Studio 2010

Get a head-start on DNN Module development. Whether you're a pro or just starting with Dotnetnuke development, you'd find DNNModule template helpful in many ways. Works on any version of VS2010.

 

Features

  • Contains one sample module with settings and Edit controls.
  • Template Base, Util and Module Controller class included
  • Easily add your own menu items from anywhere using the Base Module class
  • All folders arranged as they should be so you do not need a local Website project in your solution.
  • Local Resource File included.
  • Sample DataProvider and Uninstall DataProvider included.
  • Customized DNN ver 5.0 manifest included. Ready to Package or import as is.
  • License, Release notes with XHTML support included as sample.
  • Its free, Open Source. Download the source or just install the Template file.
  • Ready to build, Debug or package your own module in less than a minute.

 

 

 

Installation


 

DNNModule: Visual Studio Extension Installer

To install the template, download the latest release, save it in a folder of your choice, right click on it and choose unprotect. Double click on the file to launch the Template installer.
The DNNModule template is now installed.

DNNModule: Visual Studio Extension Installer

Creating a Project from DNNModule Template

DNNModule: Visual Studio Create your module

  • Fire up Visual Studio 2010 (any version), navigate to Installed Templates
  • Choose Visual C# and from the list, choose DNNModule.
  • Choose your Project name carefully, this should be the name of your module (We'll call it DNNModule1 for this walkthru).
  • Click OK in the Create Project Wizard. You should now have a complete DNN module development environment setup.

Beginning code development

  • Assuming you named your Project DNNModule1, rename DNNModule.dnn file to dnnmodule1.dnn
  • Double-Click (Open) dnnmodule1.dnnand Replace dnnmodule with dnnmodule1
  • Find out your DNN installation directory. Goto Build Events -> Post Build Events and replace the path C:\Inetpub\DNN5.2 with the correct path to your DNN installation
  • You should now be able to build your project. Every time you build, the post build events will create/copy (if needed) directories and files that need to be in the DesktopModules/DNNModule1 folder (or whatever was the module name you chose).

Installing the module into DNN for the first time.

  • Whats contained in DNNModule Option 1(Recommended): Use DNNPackager to build your module and install it via standard install interface or. You can download DNNPackager for free.
  • Option 2: Use DNN's Import manifest to import the dnnmodule1.dnnmanifest

Debugging your module

  • To Debug your module, you do not need to have the localhost Web Project in your solution. Just set a breakpoint and attach to w3wp process
  • Every time you build, the post-build events will copy the latest binaries to your DNN installation's DesktopModules/dnnmodule1 folder. Only the changed files are copied.

More about Packaging

  • The DNNModule template comes ready with license.txt and releasenotes.txt. Customize and edit them to suit your purpose.
  • Irrespective of any junk you may collect in your DesktopModules/dnnmodule1 directory, keep your manifest file up to date. If you're using DNNPackager to build your install PA, you do not need to worry about excluding files.
  • The default SqlProvider files should be customized to perform the creation of your DB schema, objects and procedures. Version them and keep the manifest file updated.

 

Where to download DNNModule Visual Studio Template from?

Head out to codeplex. DNNModule is Open Source which means, you can also contribute to it.

You can also download DNNModule template from Snowcovered.

Features, suggestions, questions and comments are very welcome.

  
 You may also be interested in
  
 Comments & Discussions

  • Gravatar
    Abel Braaksma Monday, August 30, 2010 at 5:59 AM

    In your instructions under "Beginning code development", many sentences don't end and have missing words. I.e., the first one: whereto should you rename the *.dnn file?

    Other than that: great template!

    • Gravatar
      Subodh Monday, August 30, 2010 at 7:18 PM

      Thanks Abel. I've corrected those (had some issues with PRE formatting tags)

  • Gravatar
    Billy Tee Sunday, September 12, 2010 at 10:00 AM

    Great template. Where can I download the DNNPackager for free?

    Thanks.

  • Gravatar
    Ahmad Masykur Saturday, December 11, 2010 at 7:42 AM

    Is DNNPackager still free to download? I look at snowcovered that the tools is not free.

  • Gravatar
    Dush Friday, December 24, 2010 at 3:20 PM
    VB Version ?
    Does it support VB ?

  • Gravatar
    gus Sunday, February 27, 2011 at 5:01 AM

    Hi

    I am trying out your template to get me started with module development so thanks for taking the trouble to provide it. I have run into a number of problems with the web.config and ended up stripping it out completely just to get the project to run (it builds fine).

    this is the error I was getting:

    Cannot register or retrieve components until ComponentFactory.Container is set

    After stripping out web.config the project runs but it just show a directory listing. I assume that the user control for the module needs a page to be shown in. I want to build the module outside of DNN and then package later. How do you suggest I do this? Add a .aspx page and use that to show the control? But if I do that won't it get copied into DNN after each build?

    So further advice would be really useful on using your template effectively.

    thanks
    Gus

    • Gravatar
      Subodh Sunday, February 27, 2011 at 3:09 PM

      If I get this right, you're probably using the web.config that is part of the project somewhere in your IIS. Let me clarify this a bit -- "You should absolutely not." happy
      Here's the reason. Your IIS web.config is different and should be as is. the reason you have a 2nd web.config in the Project is so that intellisense works fine and Visual Studio knows what references you're working. however once you have built and deployed the dll and the ascx control files, the project web.config has no role to play.

      Please let me know if this does not make sense.

  
Locations of visitors to this page Clicky Web Analytics 

Subodh's Blog Rating

 

DISCLAIMER

The opinion expressed
on this page 
is strictly that
of the page author
who has a
habit of animating
day-dreaming
and
fictionalizing
out of thin air.
 

The contents of this page
have not been
reviewed 
nor
approved
by 
Yahoo!

 Follow this blog
  
 Tag Cloud
  
Archives
 

Top 5 Posts of Last year
Copyright © 1995-2009 Subodh Shakya. All rights reserved.{Powered by SpeedBlog}