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

HomeHomeDevelopment and...Development and...Getting StartedGetting StartedCustom Module ASP.NET Controls causing ErrorsCustom Module ASP.NET Controls causing Errors
Previous
 
Next
New Post
5/5/2012 4:09 PM
 

Hi,

I am having an issue with a module I developed. Anything that is an asp.net Control wont render on the page and is causing errors when I either assign it to a handler, such as a button click event, or if I try to assign a value to it. Such as 

hidUserID.Value = userID.ToString(); 

or 

this.btnNewCategory.Click += new System.EventHandler(this.btnNewCategory_Click);

If I comment out these things, the module will load correctly, including grabbing information from my database tables. The error that shows up is the following:

DotNetNuke.Services.Exceptions.PageLoadException: Object reference not set to an instance of an object. ---> System.NullReferenceException: Object reference not set to an instance of an object. at DotNetNuke.Modules.QuestList.View.Page_Load(Object sender, EventArgs e) at System.Web.UI.Control.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) --- End of inner exception stack trace --- 

Does anyone know what might be going on? This is a WAP Module developed with C#.NET. My thinking was that it has something to do with the designer.cs file causing some issues.

Thanks,

Chris

 
New Post
5/8/2012 7:12 AM
 

Hi

I think you need to go to the properties of project and - set  start url, project url and click on virtual directory button then set override application root url.

 Then build your project again and check.

Thanks
Sibabrata
Mindfire Solutions

 
New Post
5/9/2012 11:40 AM
 
Hi Sibabrata,

My Start URL is currently already set to http://localhost/dotnetnuke
ProjectURL is http://localhost/dotnetnuke/desktopmodules/WozList
and override application root URL is checked and has a value of http://localhost/dotnetnuke

Are these correct?

Chris
 
New Post
5/9/2012 12:10 PM
 
So I just noticed something, becuase after manually putting information into the database to see if some stuff was running correctly, my styles were not working either. So I copied the module.css file out of my server on my live site, and opened the file and it was blank. I did the same for the view.designer.cs file and it is also basically blank, there was some basic stuff in it with setting the partial class etc.

I tried copying my test module.css, which I confirmed has the correct styles in it, to my live site. reload, still not showing my styles. When I recopy the file out of the Live site and open it is blank again.

I am pretty sure that this is the reason that I am having errors with the ASP.NET controls.

Anyone have any ideas?

Thanks,

Chris
 
Previous
 
Next
HomeHomeDevelopment and...Development and...Getting StartedGetting StartedCustom Module ASP.NET Controls causing ErrorsCustom Module ASP.NET Controls causing Errors


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