Updating the SiteMapProvider along with the postback

M

Madhur

Hello

I am using a custom SqlSiteMapProvider which I am holding in the Cache
object.

There is an Update button which removes the item from the cache, so that
when next time BuildSiteMap() is called, it is refreshed.

The problem is , the sitemap is not updated during the postback caused by
the Update Button, but during any subsequent postback.

I understand, this is because, BuildSiteMap() is first called in the page
life cycle and then the Update() postback event handler is called which
invalidates the cache, causing the old sitemap to appear. Is there any
workaround for this issue ?

Thanks in Advance

Madhur
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,812
Latest member
GracielaWa

Latest Threads

Top