Cached modules: How to tell CachedPortalModuleControl that a Module content has changed ?
Messages   Related Types
This message was discovered on ASPFriends.com 'aspngibuyspy' list.


Uwe Lesta

Hi to all off you,

Can someone tell me :
How to tell CachedPortalModuleControl that a Module content has changed ?

or

In other words How to delete the cache for a specified module ?

--

Kind regards

Uwe
Click here to reveal e-mail address

Reply to this message...
 
    
Phil Orion
I do not know the exact answer but I know where to start the investigation...
Within the desktopdefault.aspx you'll find the following code block
The If Then Else tests for the condition --if the module is cached?
Under the Else Condition ( the module is cached) , you'll have to find some way to test if the module has been updated...
If the module requires updating then disregard the cache and generate the module as in the "If" portion of the code.

For Each _moduleSettings In _portalSettings.ActiveTab.Modules

Dim parent As Control = Page.FindControl(_moduleSettings.PaneName)

' If no caching is specified, create the user control instance and dynamically
' inject it into the page. Otherwise, create a cached module instance that
' may or may not optionally inject the module into the tree
If _moduleSettings.CacheTime = 0 Then
Dim portalModule As PortalModuleControl = CType(Page.LoadControl(_moduleSettings.DesktopSrc), PortalModuleControl)

portalModule.PortalId = _portalSettings.PortalId
portalModule.ModuleConfiguration = _moduleSettings

parent.Controls.Add(portalModule)
Else
Dim portalModule As New CachedPortalModuleControl()

portalModule.PortalId = _portalSettings.PortalId
portalModule.ModuleConfiguration = _moduleSettings

parent.Controls.Add(portalModule)
End If
' Dynamically inject separator break between portal modules
parent.Controls.Add(New LiteralControl("<" & "br" & ">"))
parent.Visible = True
Next _moduleSettings

Phil
http://www.orionsmith.com

"Uwe Lesta" <Click here to reveal e-mail address> wrote in message news:687743@aspngibuyspy...
[Original message clipped]

Reply to this message...
 
 
System.Web.UI.LiteralControl
System.Web.UI.Page




Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
 
 Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us - Terms of Use - Privacy Policy - www.dotnet247.com