c# - Why does my WPF dialog appear in my task manager -> application? -


i have added new dialog in existing wpf application (say myapplication.exe). dialog name mydialog.

when executing myapplication.exe, application launches. working fine.

but after opening mydialog, found mydialog entry in task manager -> applications. if close dialog, disappears.

i don't know happening? please help.

created dialog in visual studio using following steps:

project property -> add -> add new item -> wpf -> user control (wpf). 

however, under wpf, there 1 option "user control(wpf)". there no other options (like page, window). strange.

added code:

<base:wpfmodaldialog x:class="mapinfo.mipro.mitileserver.wmtscontrol"       xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"       xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"       xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"        mc:ignorable="d"        width="650" height="600"       xmlns:local="clr-namespace:mapinfo.mipro.mitileserver"       title="open wmts table"       xmlns:base="clr-namespace:mapinfo.mipro.base;assembly=mibase"       d:designheight="300" d:des6ignwidth="300">     <grid>     ....     </grid> </base:wpfmodaldialog> 

i have not tested might try setting owner of dialog window found suggested here.

if try setting owner property of windows don't want appear, won't listed in task list. ownerless windows appear listed.

and suggest well

you can use showintaskbar="false" in window xaml file.

i found similar question has been answered stop windows showing 'tasks' task manager wpf c#.


Comments