Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Using ASP within the DNN frameworkUsing ASP within the DNN framework
Previous
 
Next
New Post
5/24/2006 8:23 AM
 

Hi fellow developpers,
I have an existing application that uses ASP (not ASP.NET) to implement INSERT/UPDATE/DELETE actions on a page showing some RECORDS. How difficult is it to port into a DNN module ?

The idea is that the code reduces the need to refresh the page, e.g. displaying detailed data gotten from the <TD> data on the client side and avoids going to the server and avoids even AJAX requests for data . For the said actions, it calls the server only when actually updating the database.

 
New Post
5/24/2006 11:57 PM
 

It really depends on how well the ASP script was written, but I have found it a breeze to get old ASP sites working in ASP.NET. Just cut and paste the code into a web form and see what the compiler says. On the other hand ASP allowed some pretty sloppy code which ASP.NET will gladly bring to your attention. The biggest issues are related to variable declarations, data types and function return values.

Helpful hints

  • First try to port it to ASP.NET (.aspx) to make sure it works, then worry about converting parts to DNN modules (.ascx).
  • Process the #include files first as normal modules.
  • Any sub or function with a Request or Response belongs in the web form .aspx (Inherits System.Web.UI.Page) or in DotNetNuke it is a user control .ascx (Portal.Module.Base) (or more likely should be converted to a string function)
  • Class Properties (get/set) need to be handled manually.
  • Even with hundreds of errors on a page, they will disappear as you provide the necessary variable declarations, data types and code placement.

I found that it only took a few minutes to port each page of a very large asp application.


Dwayne J. Baldwin
 
New Post
5/25/2006 4:59 AM
 

Thanks for the hints.

However, it doesn't seem to work for me. I'll try to explain a simple ASP case:

In Query.ASP, I have a <FORM ACTION="Submit.ASP" METHOD="Post"> and several INPUT tags with information for inserting a record when the user hits <INPUT TYPE="Submit" VALUE="Submit">.

In Submit.ASP, the corresponding data is extracted and the INSERT instruction is created.

These two pages are tested as is, and I can see the data inserted (both with an ASP page and an ASPX page that reads from the same database table.

The fun part is when I put the Query.ASP code into an ASPX page, with <FORM> at the very beginning, and the data input section in a div, when I hit the Submit button, there seems to be some disk i/o, but I can't see the data inserted. There seems to be some basic incompatibility somewhere, but my Script debugger didn't report any error.

Any help is welcome

 
New Post
5/25/2006 10:02 AM
 
If you're simply wanting to migrate your existing application to DNN, I'd suggest leaving your ASP app as-is and using the IFrame to point to it. I know this isn't what you're asking, but if migration is your issue, then this is a proven approach.

When it comes time to convert, trying it in a regular ASPX page first would be best, as Dwayne mentioned.

Michael Flanakin | Microsoft Consulting Services
www.michaelflanakin.com
 
New Post
5/26/2006 5:53 AM
 

Whoops! I forgot one big difference between ASP and ASP.NET – ASP.NET uses a single form interface that posts back to itself, not to a new page that knows nothing about the controls on the original page. In addition, ASP.NET ignores controls outside of the first server side form (<form runat="server">) and will raise an exception if you attempt to use multiple server side form tags either declared or coded.

It is very difficult to imagine what you are working with and even more difficult to explain using this medium. Often the code on the receiving page belongs in the sending page itself. Most ASP developers encounter this forms hurdle when transitioning to ASP.NET.

Michael deserves a pat on the back for this one - IFrames may be your best bet as an interim solution.


Dwayne J. Baldwin
 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Using ASP within the DNN frameworkUsing ASP within the DNN framework


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out