http://topic.
记得...
shockwaveflash可以播放SWF
shockwaveflash不能播放FLV
试了一下居然可以...
是Flash有改版吗?
程序代码:
Private Declare Function GetTempPath Lib "kernel32" Alias "GetTempPathA" (ByVal nBufferLength As Long, ByVal lpBuffer As String) As Long
Dim tempfile As String, A
Public Sub LoadM(ByVal flvfile As String)
flvfile = tempfile & "?file=" & flvfile
flvfile = Replace(flvfile, "\", "/")
ctrl.FlashVars = "autostart=true"
Call ctrl.LoadMovie(0, flvfile)
End Sub
Private Sub Command1_Click()
LoadM (A)
End Sub
Private Sub Command2_Click()
LoadM (dlg.FileName)
End Sub
Private Sub Form_Load()
Dim Buf As String * 128
Dim Value As Integer
Value = GetTempPath(128, Buf)
tempdir = Left(Buf, Value)
Randomize Timer
tempfile = tempdir & Int(Rnd * 100000) + 187
extractress tempfile
End Sub
Private Sub OpenFile_Click()
With dlg
.DefaultExt = "flv"
.Filter = "Flash video file (*.flv)|*.flv"
.Flags = cdlOFNExplorer
End With
dlg.ShowOpen
If dlg.FileName = "" Then Exit Sub
End Sub
Public Sub extractress(nom_fich As String)
Dim tab_ani() As Byte
Open nom_fich For Binary Access Write As 1
tab_ani = LoadResData(101, "CUSTOM")
ReDim Preserve tab_ani(UBound(tab_ani))
Put 1, , tab_ani
Close 1
A = nom_fich
End Sub
[
本帖最后由 wube 于 2012-7-18 12:49 编辑 ]