How to determine whether my application is active (has focus)

前端 未结 5 1268
天命终不由人
天命终不由人 2021-02-05 18:53

Is there a way to tell whether my application is active i.e. any of its windows has .IsActive=true?

I\'m writing messenger app and want it to flash in taskbar when it is

5条回答
  •  臣服心动
    2021-02-05 19:46

    You can subscribe to Main Window's Activated event, and then do whatever you want. Can you give it a try?

提交回复
热议问题