怎样拉伸flash画面大小来适应窗口大小(已解决)
本帖最后由 fuldho 于 2012-2-25 14:49 编辑看了sanhen大侠帖子:调用Flash的两个函数
http://www.autoitx.com/forum.php?mod=viewthread&tid=1746&extra=&page=1
不知怎样拉伸flash画面大小来适应窗口大小
先谢谢了!#include <GuiConstantsEx.au3>
Opt('MustDeclareVars', 1)
_Main()
Func _Main()
Local $Flash,$FlashXml,$Bbs,$msg
GUICreate("Flash 播放器", 570, 320)
$Flash = _CreateSWF( @ScriptDir &'\chojimali.swf',10,10,550,300)
GUISetState()
While 1
$msg = GUIGetMsg()
Switch $msg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd
EndFunc ;==>_Main
Func _CreateSWF($SWFPath, $SWFL, $SWFT, $SWFW, $SWFH, $SWFBGColor = "#505050")
Local $SWFObj,$SWFActiveX
$SWFObj = ObjCreate("ShockwaveFlash.ShockwaveFlash")
$SWFActiveX = GUICtrlCreateObj( $SWFObj, $SWFL, $SWFT, $SWFW, $SWFH)
With $SWFObj
.Movie = $SWFPath
.ScaleMode = 3 ;0 showall, 1 noborder, 2 exactFit, 3 noscale
.bgcolor = $SWFBGColor
.Loop = True
.allowScriptAccess = "Always"
EndWith
Return $SWFObj
EndFunc GUICreate('Flash 播放器', 570, 320)
Local $Obj = ObjCreate('ShockwaveFlash.ShockwaveFlash.9')
If @error Then Exit
If Not GUICtrlCreateObj($Obj, 10, 10, 550, 300) Then Exit
GUISetState()
$Obj.Movie = @ScriptDir & '\chojimali.swf'
$Obj.Play()
While GUIGetMsg() <> -3
WEnd
GUIDelete()
Exit 非常感谢 afan 版主!
页:
[1]