Link to home
Start Free TrialLog in
Avatar of rvcw
rvcw

asked on

TextBlock Stops Updating

Hello,

I have 3x TextBlocks which update every few seconds based on a timer. I have added an additional empty page/form on c# and a button to navigate to the page/form and another to return back to the main page.

When I return back to the main page, the TextBlocks are no long updating even though I confirmed the timer is running and the methods being triggered by the timer are also functioning.

My code to update the TextBlock looks like this:
        private string setProbeOne
        {
            set { var task = this.Dispatcher.RunAsync(Windows.UI.Core.CoreDispatcherPriority.Normal, () => { txtTemp.Text = value; }); }
        }

Open in new window


I confirmed through debugging that the timer is working and that the value is being passed to the property so I'm confused as to why the TextBlock no longer updates when I return to the page.

Any help is appreciated, thanks in advance.
Avatar of rvcw
rvcw

ASKER

Just wanted to add that this is in relation UWP and not related to ASP pages. By page, I mean a Form/Frame.
ASKER CERTIFIED SOLUTION
Avatar of Russ Suter
Russ Suter

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial