DELPHI 让窗体不在任务栏显示
2010-02-19 13:40
609 查看
需要用到的一个函数:
其中nIndex GWL_EXSTYLE Retrieves the extended window styles.
dwNewLong WS_EX_TOOLWINDOW Creates a tool window; that is, a window intended to be used as a floating toolbar. A tool window has a title bar that is shorter than a normal title bar, and the window title is drawn using a smaller font. A tool window does not appear in the taskbar or in the dialog that appears when the user presses ALT+TAB. If a tool window has a system menu, its icon is not displayed on the title bar. However, you can display the system menu by right-clicking or by typing ALT+SPACE.
有关dwNewLong的更多预定义值的含义,请自行查阅CreateWindowEx的帮助信息
在窗体创建事件中加入:
如果要整个程序不在任务栏显示,可以在dpr工程文件中加入以上代码,例如:(需要引用Windows单元)
LONG SetWindowLong( HWND hWnd, int nIndex, LONG dwNewLong );
其中nIndex GWL_EXSTYLE Retrieves the extended window styles.
dwNewLong WS_EX_TOOLWINDOW Creates a tool window; that is, a window intended to be used as a floating toolbar. A tool window has a title bar that is shorter than a normal title bar, and the window title is drawn using a smaller font. A tool window does not appear in the taskbar or in the dialog that appears when the user presses ALT+TAB. If a tool window has a system menu, its icon is not displayed on the title bar. However, you can display the system menu by right-clicking or by typing ALT+SPACE.
有关dwNewLong的更多预定义值的含义,请自行查阅CreateWindowEx的帮助信息
在窗体创建事件中加入:
SetWindowLong(Application.Handle,GWL_EXSTYLE,WS_EX_TOOLWINDOW);
如果要整个程序不在任务栏显示,可以在dpr工程文件中加入以上代码,例如:(需要引用Windows单元)
begin Application.Initialize; SetWindowLong(Application.Handle,GWL_EXSTYLE,WS_EX_TOOLWINDOW); Application.CreateForm(TForm1, Form1); Application.Run; end.
相关文章推荐
- showdialog窗体不在任务栏显示的问题处理
- DELPHI 让子窗体显示在任务栏上
- DELPHI 让子窗体显示在任务栏上
- Delphi XE4 主窗体隐藏之后任务栏没有图标显示。
- Qt圆角窗体+半透明背景+右下角显示(移除窗体标题栏+置顶+不在任务栏显示)
- Delphi 让子窗体显示在任务栏上的几种方法
- DELPHI 让子窗体显示在任务栏上
- [代码]Delphi实现窗体始终前台显示且获得焦点
- qt对话框不在任务栏显示
- 在VC中实现程序不在任务栏显示按钮, 标题栏与菜单栏的不显示
- Delphi中DLL或Package窗体载入与显示
- Delphi 类似实现QQ多窗口显示任务栏上
- c# 智能设备应用程序不显示在任务栏以及最小化窗体
- C#WinForm程序不不在任务栏显示的处理方法
- 窗体最小化后在任务栏不显示
- 让程序不在任务栏小按钮显示
- QQ登陆画面的最小化显示机制(使程序不在任务栏显示)
- Delphi 中最小化窗体是隐藏并在任务揽中显示图表和进程名
- 主窗体1显示另一个窗体2时如何让窗体2也在任务栏显示
- EXECL打开多个文件时不在任务栏上只显示一个文件窗口