Thursday, March 10, 2005
On the ASP.NET forums someone asked if you could use IFrame modules to encapsulate existing application pages. Unfortunately the answer is 'no'.Iframes are pretty much useless for using DNN user information as they result in separate requests to the server which of course is clueless about your other DNN request. So that method is out.

What I did was as follows:

- get DNN to compile/debug as-is
- install VS templates for DNN from dnnjungle (sorry, no URL handy)
- add a DNN module project to the DNN solution using the new templates
- put some simple stuff (plain text or whatever) in the view ascx
- remove code from ascx code behind that references biz layers and other db stuff
- compile
- add module to framework according to the module dev. document
- open your existing application in another VS session
- copy all text between <form></form> of your aspx to your ascx
- copy all code behind methods to your ascx.vb
- splice in the me.userid and other user related things as needed
- add your own data access project to the solution (add it to the build project as well)
- for each additional page of your original app, add another ascx to your project. No need to start a new module for that

This is what I did with a reporting application I wrote in plain ol' ASP.NET that I wanted to move into DNN. In my case the db was separate from the DNN database. In a different app that I'm writing from the ground up to use DNN I'm using the same db though. Plenty of room for other tables/procs. I use a prefix to separate the DNN stuff from my own.

Good luck!