Click here to Skip to main content
6,295,667 members and growing! (15,291 online)
Email Password   helpLost your password?
Web Development » ASP.NET » General     Intermediate

Automated Module Creation Tool for DotNetNuke

By Todd Davis

An automated approach to module creation for the DNN framework
.NET, Win2K, WinXP, Win2003, ASP.NET, Visual Studio, Dev
Posted:12 Feb 2004
Updated:23 Feb 2004
Views:83,005
Bookmarked:34 times
Announcements
Loading...
 
Search    
Advanced Search
printPrint   Broken Article?Report       add Share
  Discuss Discuss   Recommend Article Email
9 votes for this article.
Popularity: 3.82 Rating: 4.00 out of 5
1 vote, 11.1%
1
1 vote, 11.1%
2

3
3 votes, 33.3%
4
4 votes, 44.4%
5

Sample Image - CreateModuleTemplate.jpg

Introduction

DotNetNuke is an excellent portal framework built with ASP.NET. We are currently using it to build a content management system for our corporate intranet. One of the nice things about DNN is that it is modularized - you can create custom modules that are easily integrated and moved around within the framework. They can also be distributed to other web sites based on the DNN framework.

Why a tool?

Creating a new module is fairly simple, but it does take some work in regards to developer and admin time. A sample module was distributed with the documentation. Creating a new module is based largely on cutting and pasting the module info from this document, tweaking it to include the name of your new module class, tying it in the edit module, creating a separate mobile module, building and then registering everything on the website itself. It is a tedious process, and just getting the "basic shell" setup can take up otherwise valuable developer and admin time.

CreateModuleTemplate

This tool, which is itself a DNN module, will assist the developers by creating the:

  • Module ascx and vb
  • EditModule ascx and vb
  • MobileModule ascx and vb
  • Registering the module with DNN

All in one quick easy step. The picture above will give you a basic clue how this looks and works. The main page was based off of DNN's own Module Properties page, but has been greatly enhanced with JavaScript to automate the process.

Customizable

The module is also easily customized. You can choose which modules will (or will not) be created by default simply by using checkboxes. The templates themselves are based on text files, which can be customized online using CreateModuleTemplate, or by hand using your favorite editor. This allows you create module templates with your own tweaks built in.

Try it out

The download above contains the full code, and complete, detailed documentation on how the process works, including lots of images. But honestly, the process is so easy, you won't need it :)

Email-ware

If you do use CreateModuleTemplate - do me favor, and drop me an email to let me know how you like it, and if it is working for you. All the info is in the download. If you have any suggestions or enhancements (or bug fixes) please let me know so I can update the code.

DNN 2.0

DNN 2.0 beta1 was released on Feb 14, 2004. I have created a new version of CreateModuleTemplate that works with DNN2b1. Please make sure that you download the correct version of CMT for your DNN portal. Please note that this version is extremely new, and hasn't been extensively tested, nor does it take advantage of all the features available in DNN2b1. What it will do is create the module templates and register them in the most generic way possible for quick and smooth addition. The "icon" feature has been removed in this version (no icon is assigned by default), and the "version" field has been added, but no JavaScript is hooked up to that yet. Note that the docs are the same ones from v1, as nothing has functionally changed.

Warning: Since this is beta code running on a beta framework, I'd strongly suggest that it not be used in a production environment. As new changes appear in DNN2, this code may cease to function. Use at your own risk.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

Todd Davis


Member
Todd Davis has been working in web and application development for several years, using ASP.NET, VB.NET, C#, C++ and Javascript, as well as a great deal of work with SQL server and IIS.

He currently works for Eclipsys in Great Valley, PA. however he is better known for his varied work in the open source community, especially the DotNetNuke project for which he provided several world-renowned training videos and modules. A huge advocate of open source and open knowledge sharing, everything on his website (www.SeaburyDesign.com) is always offered for free.

Whenever he is not actively coding at his laptop (a rarity to be sure), he can be found watching SpongeBob Squarepants with his daughter Katja, or motoring along the backroads of PA on his Harley Davidson Fatboy.
Occupation: Web Developer
Location: United States United States

Other popular ASP.NET articles:

Article Top
You must Sign In to use this message board.
FAQ FAQ 
 
Noise Tolerance  Layout  Per page   
 Msgs 1 to 19 of 19 (Total in Forum: 19) (Refresh)FirstPrevNext
GeneralYou Rule PinmemberTony Leotta4:40 17 Sep '05  
GeneralDoes this work with 3.1 Pinmemberpeternolan96:25 11 Jul '05  
GeneralRe: Does this work with 3.1 PinmemberTodd Davis6:30 11 Jul '05  
GeneralRe: Does this work with 3.1 Pinmemberpeternolan96:57 11 Jul '05  
GeneralHow To Install This Utility Pinmemberales_pac5:16 6 May '05  
GeneralRe: How To Install This Utility Pinmemberales_pac5:19 6 May '05  
GeneralCreating a DotNetNuke Module using notepad Pinmemberdefwebserver8:53 12 Oct '04  
GeneralDNN 2.1.2 compatible ? PinmemberPaul Chu16:59 1 Sep '04  
GeneralRe: DNN 2.1.2 compatible ? PinmemberTodd Davis5:13 2 Sep '04  
GeneralRe: DNN 2.1.2 compatible ? PinmemberPaul Chu12:09 2 Sep '04  
GeneralAutomate daily email reports using ASP.NET & SQL Server!! PinsussShashidhar_v0:41 19 Jul '04  
GeneralRe: Automate daily email reports using ASP.NET & SQL Server!! PinsussAnonymous22:05 9 Nov '04  
GeneralRe: Automate daily email reports using ASP.NET & SQL Server!! PinmemberCatalin Hatmanu12:05 3 Nov '05  
GeneralC++ Port PinsussDharmesh Shah3:54 30 May '04  
GeneralDLL missig Pinmemberzayoun14:01 14 May '04  
GeneralDNN 2.0b Install PinmemberHRybko11:40 24 Feb '04  
GeneralRe: DNN 2.0b Install PinmemberTodd Davis13:03 24 Feb '04  
GeneralRe: DNN 2.0b Install PinmemberChasin Stanley15:48 9 Mar '04  
GeneralThanks! PinmemberRick Engelking4:41 14 Feb '04  

General General    News News    Question Question    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

PermaLink | Privacy | Terms of Use
Last Updated: 23 Feb 2004
Editor: Smitha Vijayan
Copyright 2004 by Todd Davis
Everything else Copyright © CodeProject, 1999-2009
Web20 | Advertise on the Code Project