如何让我的程序抢占屏幕?

princerock 2003-09-13 04:25:03
我把程序隐藏在后台运行,想用SetTimer函数设置计时器,每隔一段时间与系统时间比较,当达到设定时间时让我的程序出现在前台,不管当前活动窗口是什么都使我的窗口成为活动的并全屏显示。怎么做啊?
...全文
35 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
shootingstars 2003-09-15
  • 打赏
  • 举报
回复
如果你使用Win2000你可能很难用WinApi完成你的功能,因为:
Windows NT 5.0 and later: An application cannot force a window to the foreground while the user is working with another window. Instead, SetForegroundWindow will activate the window (see SetActiveWindow) and call theFlashWindowEx function to notify the user.
如果你一定需要完成这个功能,可以看看下面这个帖子中的一个例子,不过好像有点复杂:
http://expert.csdn.net/Expert/topic/2221/2221820.xml?temp=.5793726
gzshd 2003-09-13
  • 打赏
  • 举报
回复
DirectDraw
vcforever 2003-09-13
  • 打赏
  • 举报
回复
用SetForeGround()函数就可以实现!
feeboby 2003-09-13
  • 打赏
  • 举报
回复
修改窗口样式可以做到
SlayerCarrier 2003-09-13
  • 打赏
  • 举报
回复
ActiveWindow

2,640

社区成员

发帖
与我相关
我的任务
社区描述
VC/MFC 硬件/系统
社区管理员
  • 硬件/系统社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧