Need to show application in SystemTray Hide it in Task Managaer
Hi To ALL!!!
I Need Some help. I did to show my application in System Tray. Now i wanna to hide the application in Task Manager.
I've find this code in Net to show in system tray. Can any one tell how to hide it in Task Manager.
BOOL CEXDlg::TrayMessage(DWORD dwMessage)
{
CString str(_T("Internet Everywhere"));
NOTIFYICONDATA nid;
nid.cbSize = sizeof(NOTIFYICONDATA);
nid.hWnd = m_hWnd;
nid.uID = IDI_TRAYICON;
nid.uFlags = NIF_MESSAGE|NIF_ICON;
nid.uCallbackMessage = MYWM_NOTIFYICON;
VERIFY (nid.hIcon = LoadIcon(AfxGetInstanceHandle(),MAKEINTRESOURCE(IDI_TRAYICON)));
nid.uFlags = NIF_MESSAGE|NIF_ICON|NIF_TIP;
lstrcpyn(nid.szTip, (LPCTSTR)str, sizeof(nid.szTip)/sizeof(nid.szTip[0]));
return Shell_NotifyIcon(dwMessage, &nid);
}
Thanks & Regards
Arjun
Re: Need to show application in SystemTray Hide it in Task Managaer
Quote:
Originally Posted by
tgm.arjun09
I Need Some help. I did to show my application in System Tray. Now i wanna to hide the application in Task Manager.
I've find this code in Net to show in system tray. Can any one tell how to hide it in Task Manager.
Why would you want to do that? That doesn't make any sense whatsoever. :confused:
EDIT:
Wait, do you mean you want to create a service? That is, an application that doesn't show up in the task bar but only in the system tray?
Re: Need to show application in SystemTray Hide it in Task Managaer
You will need to hide your window to not show it in task manager.
But it would still show in the processes tab.
Code:
ShowWindow(m_hWnd, SW_HIDE);