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

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsGalleryGalleryError in galleryError in gallery
Previous
 
Next
New Post
8/12/2005 8:35 PM
 

The Gallery only run for couple hours and then it throw an exception "reference to null object" or something else. I have to restart the App. to get it up.

thank you

 
New Post
8/24/2005 3:44 PM
 

I've been experiencing the same problem - on about 10 different websites. It's hard to provoke the bug when you want to, but generally when you do you only the shorthand. I recompiled the gallery in debug mode to discover where the bug is. Here is a more detailed output:

Message: DotNetNuke.Services.Exceptions.ModuleLoadException: beim Hinzufügen des Moduls zu ContentPane ist ein Fehler aufgetreten. ---> System.TypeInitializationException: The type initializer for "DotNetNuke.Modules.Gallery.Config" threw an exception. ---> System.NullReferenceException: Object reference not set to an instance of an object. at DotNetNuke.Entities.Portals.PortalController.GetCurrentPortalSettings() at DotNetNuke.Modules.Gallery.Config..cctor() in \Web\DesktopModules\Gallery\Components\Configuration\Config.vb:line 848 --- End of inner exception stack trace --- at DotNetNuke.Modules.Gallery.Config.GetGalleryConfig(Int32 ModuleID) at DotNetNuke.Modules.Gallery.Container.Initialize() in \Web\DesktopModules\Gallery\Container.ascx.vb:line 154 at DotNetNuke.Modules.Gallery.Container.Page_Init(Object sender, EventArgs e) in \Web\DesktopModules\Gallery\Container.ascx.vb:line 326 at System.Web.UI.Control.OnInit(EventArgs e) at System.Web.UI.UserControl.OnInit(EventArgs e) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.InitRecursive(Control namingContainer) at System.Web.UI.Control.AddedControl(Control control, Int32 index) at System.Web.UI.ControlCollection.Add(Control child) at DotNetNuke.UI.Skins.Skin.InjectModule(Control objPane, ModuleInfo objModule, PortalSettings PortalSettings) --- End of inner exception stack trace --- 
Something seems to be wrong with this part of the code in the Config.vb

Shared Sub New()

Dim _portalSettings As PortalSettings = PortalController.GetCurrentPortalSettings

'mPortalCssURL = _portalSettings.UploadDirectory & "portal.css"

End Sub

My guess is that for some reason, the PortalController hasn't been created by the time the gallery tries to access it the first time. Maybe some kind of caching? Tam, you have any idea? Because once the bug appears, it doesn't go away. I don't have the solution yet, but maybe somebody else can figure it out before me? If you do, please post!

Thanks, Daniel

 
New Post
8/24/2005 4:47 PM
 

I think I'm getting closer, bear with me...

To me it looks like we have the culprit here

Public Shared Function GetGalleryConfig(ByVal ModuleID As Integer) As DotNetNuke.Modules.Gallery.Config

Dim strKey As String = GalleryConfigCacheKeyPrefix & ModuleID.ToString

If DataCache.GetCache(strKey) Is Nothing Then

Dim config As DotNetNuke.Modules.Gallery.Config = New DotNetNuke.Modules.Gallery.Config(ModuleID)

DataCache.SetCache(strKey, config)

End If

Return CType(DataCache.GetCache(strKey), DotNetNuke.Modules.Gallery.Config)

End Function

this is the function inside Config.vb. If I'm not mistaken (I'm better an C# than VB) this is a function that can be called without creating the object first, like a static function in C#. Now it appears that if the settings have not been cached, it gets some settings an caches them. My guess is that somehow sometimes the static function runs kind of "out-of-context" and fails. Whatever causes it to be out of context, seems to persist once it "lost" its context. Probably sometimes when it has a context, things work out untill the cache clears.

Any other ideas?

 
New Post
8/29/2005 1:47 AM
 
Did anybody solve this? I still haven't worked it out.
 
New Post
8/30/2005 12:53 PM
 
Daniel:

Take a look at my (very long) post at http://forums.asp.net/1026257/ShowPost.aspx. In it, I attempted to document my experience with the deployment of DNN 3.1.0. and the Gallery v3.0.10. To make the story short and to not rewrite what's in that post, I can tell you that right now, after upgrading to DNN 3.1.1., the Gallery has not crashed any more. It still has some bugs, the buttons in the upper right hand corner of the pop-up work for one album but not another, but the gallery has been running non-stop since 8/24/05 without having to do the login as admin trick. And I did not do any of the code changes mentioned in the current thread.

I do have to mention that I am still using the periodic call to KeepAlive.aspx and the Gallery friendly URL I created. I wrote a very (very) basic screen scraping utility as a VB.Net console app that I use to invoke the sites every 15 minutes.

Hope you find this helpful.

Carlos
 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsGalleryGalleryError in galleryError in gallery


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