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

HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...binding arraylist and I keep getting an error...! Please help!binding arraylist and I keep getting an error...! Please help!
Previous
 
Next
New Post
3/13/2007 3:58 PM
 
 

Hi, I have been stuck on this for a day now and I am not quite sure what to do.

I have been following the module tutorial from the Seagate website and I am trying to grab data from a database table by binding it to a repeater and I keep getting this error:

Error: NewHtml is currently unavailable.
DotNetNuke.Services.Exceptions.ModuleLoadException: Object reference not set to an instance of an object. ---> System.NullReferenceException: Object reference not set to an instance of an object. at CompanyName.DNN.Modules.NewHTML.NewHTML.Page_Load(Object sender, EventArgs e) in C:\Inetpub\wwwroot\DotNetNuke\DesktopModules\CompanyName.NewHTML\NewHTML.ascx.vb:line 65 --- End of inner exception stack trace ---

** And here is the line that I am getting the error from:

newHTMLRepeater.DataSource = objNewHTML.ListNewHTML(PortalId, ModuleId)
newHTMLRepeater.DataBind()

Does anyone have any ideas???

THANKS IN ADVANCE!!!

 
New Post
3/13/2007 7:32 PM
 

Without seeing the code for ListNewHTML method and your repeater's databinding expressions, it's hard to say but here are a few likely possibilities to check out:

1. I asume that objNewHTML is an instance of your module's controller class. Has it been initialized (New)?
2. Perhaps a null value is being returned from the database for one of the fields that then throws the error during databinding or in hydrating the object that makes up each item of the ArrayList.  You have to be especially careful about returning null dates - look into using the Null.SetNull method when setting a property of your info class object from a datareader field that could return a null. Strings can also present a similar problem.

If you can step line by line through the code of ListNewHTML you will likely find the problem.


Bill, WESNet Designs
Team Lead - DotNetNuke Gallery Module Project (Not Actively Being Developed)
Extensions Forge Projects . . .
Current: UserExport, ContentDeJour, ePrayer, DNN NewsTicker, By Invitation
Coming Soon: FRBO-For Rent By Owner
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...binding arraylist and I keep getting an error...! Please help!binding arraylist and I keep getting an error...! Please help!


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