I ran into this problem as well. Looked in Reflector and figured out why. Seems like this is a bug to me. On the setter, if the page has a Header control, then setting the Title property actually changes Header.Title, but if the _titleToBeSet property already has a value (mine does because I'm using localized resources) then it doesn't clear out the old value and the getter still returns _titleToBeSet instead of Header.Title.
So I just changed my code to return this:
return (Page.Header != null ? Page.Header.Title : null) ?? Page.Title;
(Page.Header != null ? Page.Header.Title : null) ?? Page.Title;
by John Avis | April 9, 2019
In this, my third post on this topic, I go over the methods I am using now and the problems I have encountered and overcome.
by John Avis | February 20, 2019
I was recently doing some work on a website which has a mixture of older Classic ASP pages and ASP.NET Web Forms pages and ran into problems with custom error pages.
by John Avis | February 9, 2018
On an ASP.NET Web Forms page with multiple UpdatePanels it’s nice to give the user some feedback when one of the panels is being updated.