AsyncLocal value disappeared when Open a new window from loaded-event
fy w
1
Reputation point
when I run a wpf App, I set value to a global AsyncLocal variable and open the Second window at the Loaded-Event of MainWindow,when I click a button of the second window,the value of global AsyncLocal variable is null.But if I do this at a button click-event,it's ok.so I try to simulation the button click-event to open the second event,but it didn't work.I don't know what's wrong.