如何让按下Alt+Tab组合键时让程序的图标不显示,
隐藏如图图标:

解决方案 »

  1.   

           
            private void Form1_Load(object sender, EventArgs e)
            {
                SetWindowsAltTab(this.Handle);
            
            }        public void SetWindowsAltTab(IntPtr p_WindowsIntPtr)
            {
                int _Value = GetWindowLong(p_WindowsIntPtr, (-20));
                SetWindowLong(p_WindowsIntPtr, (-20), _Value | 0x00000080);        }        [DllImport("user32.dll", EntryPoint = "GetWindowLong")]
            public static extern int GetWindowLong(IntPtr hwnd, int nIndex);        [DllImport("User32.dll", CharSet = CharSet.Auto)]
            public static extern int SetWindowLong(IntPtr hWnd, int nIndex, int dwNewLong);
      

  2.   

    有点不明白楼主想要的是什么效果...
    是将你的程序从工具栏中隐藏吗,那么你在做程序的时候将其设置不在工具栏中显示就可以了,那么Alt+Tab就看不到的
      

  3.   

    看到图标了,选中子窗体,然后设置属性:showintaskbar=false;
      

  4.   

    没那么复杂吧。
     public Form1() {
                InitializeComponent();
                ShowInTaskbar = false;
                this.FormBorderStyle = FormBorderStyle.SizableToolWindow; // or 
                //or
                //this.FormBorderStyle = FormBorderStyle.FixedToolWindow; 
            }