找回密码
 加入
搜索
查看: 1861|回复: 11

au3怎么实现启动窗口界面渐显效果呢

[复制链接]
发表于 2009-8-28 12:12:10 | 显示全部楼层 |阅读模式
就像下面这个程序界面,au3可以实现吗,那个提示窗口不要的,谁能贴下源码,谢谢拉



本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?加入

×
发表于 2009-8-28 13:00:21 | 显示全部楼层
[au3]#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 633, 447, 192, 124)
WinSetTrans("Form1", "", 0)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

$i=0
Do
        WinSetTrans("Form1", "", $I)
        $I += 1
Until $I = 255

While 1
        $nMsg = GUIGetMsg()
        Switch $nMsg
                Case $GUI_EVENT_CLOSE
                        Exit

        EndSwitch
WEnd[/au3]
 楼主| 发表于 2009-8-28 13:23:31 | 显示全部楼层
你好:有个小问题想请教下:如果启动一个外部程序的时候,比如记事本,怎么实现这种效果呢?

代码是一样的吗,我测试了下好像不行....望指点,谢谢
发表于 2009-8-28 13:56:40 | 显示全部楼层
[au3]run("notepad.exe",@WindowsDir,@SW_HIDE)
Sleep(100)
WinSetTrans("[CLASS:Notepad]", "", 0)
WinSetState ("[CLASS:Notepad]", "",@SW_SHOW)
WinActivate ("[CLASS:Notepad]")
$i=0
Do
        WinSetTrans("[CLASS:Notepad]", "", $I)
        $I += 1
Until $I = 255[/au3]
 楼主| 发表于 2009-8-28 16:41:21 | 显示全部楼层
感谢提供相关代码,不过好像只能是记事本程序可以的,我尝试换其他的软件,比如QQ2009安装程序,好像还是实现不了那种效果,真奇怪了   
代码是不是还要修改下呢,谢谢
发表于 2009-8-28 16:51:40 | 显示全部楼层
测试正常
10字补丁
 楼主| 发表于 2009-8-28 20:17:15 | 显示全部楼层
我想安装的是这个软件:http://download.iciba.com/upwl/powerwordlite.38410.0.exe
安装的时候想让他出现窗口渐显的半透明效果,可以帮写个au3源码么?  多谢多谢

发表于 2009-8-31 16:20:50 | 显示全部楼层
大灰狼这种 就是吃力不讨好类型了

如果一上来就不给代码 让楼主理解原理思路 那就不管什么软件都可以搞定了

而不是 2个人在这里浪费大家的事件
发表于 2009-8-31 21:23:28 | 显示全部楼层
本帖最后由 水木子 于 2009-8-31 21:26 编辑

我也是新人,大家共同学习吧!
不知道这样会不会让你更容易理解。
#include <GUIConstantsEx.au3>
#include <SliderConstants.au3>
#include <WindowsConstants.au3>

$Form1 = GUICreate("滑动调整透明度", 400, 300, -1, -1)
$Label1 = GUICtrlCreateLabel("调整滑动条更改窗体透明度", 80, 80, 300, 30)
GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif")
$Slider1 = GUICtrlCreateSlider(50, 120, 300, 50)
GUICtrlSetLimit($Slider1, 250, 10)
GUICtrlSetData($Slider1,250)
GUISetState(@SW_SHOW)
AdlibEnable("xian", 100)

While 1
        $nMsg = GUIGetMsg()
        Switch $nMsg
                Case $GUI_EVENT_CLOSE
                        Exit

        EndSwitch
WEnd

Func xian()
        $a = GUICtrlRead($Slider1)
        WinSetTrans("滑动调整透明度","",$a)
EndFunc        
发表于 2009-8-31 23:50:20 | 显示全部楼层
本帖最后由 hnzzlzj 于 2009-9-1 00:00 编辑
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>

$hwnd = GUICreate("Animate Window", 300, 300)
$hwnd = GUICreate("Animate Window", 300, 300)
DllCall("user32.dll", "int", "AnimateWindow", "hwnd", $hwnd, "int", 3000, "long", 0x00080000)
GUISetState()

While 1
        $nMsg = GUIGetMsg()
        Switch $nMsg
                Case $GUI_EVENT_CLOSE
                        DllCall("user32.dll", "int", "AnimateWindow", "hwnd", $hwnd, "int", 3000, "long", 0x00090000)
                        Exit

        EndSwitch
WEnd
发表于 2009-8-31 23:55:07 | 显示全部楼层
SplashImageOn($cap, $pop,380,512,-1,780,16)
ToolTip ("请不要关闭,五秒后自动退出",820,650,"至尚公告",1)
Opt("WinTitleMatchMode", 2)
For $iTrans = 255 to 50 Step -0.5
WinSetTrans($cap, "", $iTrans)
NEXT
For $iTrans = 780 to 10 Step -0.01
    winmove($cap, "", default,$iTrans)
Next
For $iTrans = 50 to 255 Step 0.2
WinSetTrans($cap, "", $iTrans)
NEXT
Sleep(80000)
SplashOff()
Exit
发表于 2009-9-1 04:15:26 | 显示全部楼层
像这种问题 就应该说

循环 设置透明度
您需要登录后才可以回帖 登录 | 加入

本版积分规则

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-9-22 21:13 , Processed in 0.084456 second(s), 25 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表