feicuiboy 发表于 2009-8-5 23:26:47

看不懂此语句

看不懂此语句,高手解释下,谢谢

Dim $sTitle
Func AnimateTitle($hGUI, $sTitle, $iBuf)
    $sTitle = StringSplit($sTitle, "")
    For $i = $iBuf To 0 Step - 1
      WinSetTitle($hGUI, "", _StringRepeat(" ", $i) & $sTitle)
    Next
    Local $s
    For $i = 1 To $sTitle
      $s &= $sTitle[$i]
      WinSetTitle($hGUI, "", $s)
      Sleep(5)
    Next
EndFunc

pusofalse 发表于 2009-8-6 00:18:33

#include <String.au3>

Dim $sTitle = "Animate Title"
$hForm = GUICreate($sTitle, 400, 300)
GUISetState()
AnimateTitle($hForm, $sTitle, 100)

Do
Until guiGetMsg() = -3

Func AnimateTitle($hGUI, $sTitle, $iBuf)
        $sTitle = StringSplit($sTitle, "")
        For $i = $iBuf To 0 Step - 1
                WinSetTitle($hGUI, "", _StringRepeat(" ", $i) & $sTitle)
        Next
        Local $s
        For $i = 1 To $sTitle
                $s &= $sTitle[$i]
                WinSetTitle($hGUI, "", $s)
                Sleep(5)
        Next
EndFunc这样看懂了吗?

autoit3CN 发表于 2009-8-6 00:52:40

其实就是字符串的控制
楼主还是去温习下相关函数吧
页: [1]
查看完整版本: 看不懂此语句