下载此文档

C如何让WinForm嵌入桌面窗口最底层4页.docx


文档分类:IT计算机 | 页数:约4页 举报非法文档有奖
1/4
下载提示
  • 1.该资料是网友上传的,本站提供全文预览,预览什么样,下载就什么样。
  • 2.下载该文档所得收入归上传者、原创者。
  • 3.下载的文档,不会出现我们的网址水印。
1/4 下载此文档
文档列表 文档介绍
此类将窗体永远置于窗口最底层。
首先, 的WinAPI函数。
internal class User32
public const int SE_SHUTDOWN_PRIVILEGE0x13;
[DllImport( "")]
public static extern IntPtr FindWindow( string lpClassName, string lpWindowName);
[DllImport( "")]
public static extern IntPtr SetParent(IntPtr hWndChild, IntPtr hWndNewParent);
[DllImport( "")]
public static extern bool SetWindowPos(IntPtr hWnd, int hWndInsertAfter, int X, int Y, int cx,
int cy, uint uFlags);
然后,在WinForm里面: public MainForm()
InitializeComponent();
try if ( < 6)
();
IntPtr hWndNewParent = ( "Progman", null );
( ,
hWndNewParent); else
0, );
catch (ApplicationException exx)
( this , , "Pin to
Desktop");
private void MainForm_Activated( object sender, EventArgs
e)
if (Envir

C如何让WinForm嵌入桌面窗口最底层4页 来自淘豆网m.daumloan.com转载请标明出处.

相关文档 更多>>
非法内容举报中心
文档信息
  • 页数4
  • 收藏数0 收藏
  • 顶次数0
  • 上传人changjinlai
  • 文件大小69 KB
  • 时间2021-07-23